wip to Core

master
rob 2 years ago
parent b124d266d6
commit 8f597dc5e5

@ -111,6 +111,10 @@ class OAuth2Service extends SiteService {
app.post(
'/oauth2/token',
(req, res, next) => {
this.log.debug('POST /oauth2/token', { body: req.body, params: req.params, query: req.query });
return next();
},
passport.authenticate(['basic', 'oauth2-client-password'], { session: false }),
this.server.token(),
this.server.errorHandler(),
@ -178,8 +182,6 @@ class OAuth2Service extends SiteService {
username_lc: authCode.user.username_lc,
displayName: authCode.user.displayName,
bio: authCode.user.bio,
permissions: authCode.user.permissions,
flags: authCode.user.flags,
},
};
await Promise.all([

Loading…
Cancel
Save