mirror of
https://github.com/TryGhost/Ghost.git
synced 2025-02-03 23:00:14 -05:00
Fixed invalid method usage in members authentication
no issue - `getPublicConfig` in members authentication was not called correctly
This commit is contained in:
parent
b35269f933
commit
15a3dacf26
1 changed files with 2 additions and 2 deletions
|
@ -18,14 +18,14 @@ module.exports = {
|
||||||
const {protocol, host} = url.parse(config.get('url'));
|
const {protocol, host} = url.parse(config.get('url'));
|
||||||
const siteOrigin = `${protocol}//${host}`;
|
const siteOrigin = `${protocol}//${host}`;
|
||||||
|
|
||||||
UNO_MEMBERINO = membersService.getPublicConfig().then(({issuer}) => jwt({
|
UNO_MEMBERINO = membersService.api.getPublicConfig().then(({issuer}) => jwt({
|
||||||
credentialsRequired: false,
|
credentialsRequired: false,
|
||||||
requestProperty: 'member',
|
requestProperty: 'member',
|
||||||
audience: siteOrigin,
|
audience: siteOrigin,
|
||||||
issuer,
|
issuer,
|
||||||
algorithm: 'RS512',
|
algorithm: 'RS512',
|
||||||
secret(req, payload, done) {
|
secret(req, payload, done) {
|
||||||
membersService.getPublicConfig().then(({publicKey}) => {
|
membersService.api.getPublicConfig().then(({publicKey}) => {
|
||||||
done(null, publicKey);
|
done(null, publicKey);
|
||||||
}).catch(done);
|
}).catch(done);
|
||||||
},
|
},
|
||||||
|
|
Loading…
Add table
Reference in a new issue