Kaynağa Gözat

Merge pull request 'Send a scope with access token' (#605) from trondd555/snac2:token_scope into master

Reviewed-on: https://codeberg.org/grunfink/snac2/pulls/605
grunfink 3 ay önce
ebeveyn
işleme
ca24e28930
1 değiştirilmiş dosya ile 2 ekleme ve 0 silme
  1. 2 0
      mastoapi.c

+ 2 - 0
mastoapi.c

@@ -412,6 +412,8 @@ int oauth_post_handler(const xs_dict *req, const char *q_path,
 
                 if (!xs_is_null(scope))
                     rsp = xs_dict_append(rsp, "scope", scope);
+                else
+                    rsp = xs_dict_append(rsp, "scope", "");
 
                 *body  = xs_json_dumps(rsp, 4);
                 *ctype = "application/json";