Updated example

no-issue
This commit is contained in:
Fabien O'Carroll 2019-04-11 16:26:51 +02:00
parent 27bb3a6955
commit 32e81fb030

View File

@ -30,7 +30,7 @@ const server = require('http').createServer((req, res) => {
res.writeHead(200);
res.end();
}).catch((err) => {
res.writeHead(err.code);
res.writeHead(err.statusCode);
res.end(err.message);
});
} else {
@ -40,7 +40,7 @@ const server = require('http').createServer((req, res) => {
});
res.end(JSON.stringify(member));
}).catch((err) => {
res.writeHead(err.code);
res.writeHead(err.statusCode);
res.end(err.message);
});
}
@ -51,7 +51,7 @@ server.listen(0, '127.0.0.1', () => {
const url = `http://${address}:${port}`;
const token = jwt.sign({}, keys.private, {
issuer: 'example.com',
audience: 'members-ssr',
audience: 'example.com',
algorithm: 'RS512'
});