mirror of
https://iceshrimp.dev/crimekillz/iceshrimp-161sh.git
synced 2024-11-21 19:53:50 +01:00
[mastodon-client] Fix scope parameter in /oauth/token
This commit is contained in:
parent
f2d7716f1a
commit
b45be30d19
@ -94,7 +94,7 @@ export class AuthHelpers {
|
||||
|
||||
public static async getAuthToken(ctx: MastoContext) {
|
||||
const body: any = ctx.request.body || ctx.request.query;
|
||||
const scopes: string[] = (typeof body.scopes === "string" ? body.scopes.split(' ') : body.scopes) ?? ['read'];
|
||||
const scopes: string[] = (typeof body.scope === "string" ? body.scope.split(' ') : body.scope) ?? ['read'];
|
||||
const clientId = toSingleLast(body.client_id);
|
||||
const code = toSingleLast(body.code);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user