fastify-jwt
Advanced tools
Comparing version 0.9.2 to 0.9.3
{ | ||
"name": "fastify-jwt", | ||
"version": "0.9.2", | ||
"version": "0.9.3", | ||
"description": "JWT utils for Fastify", | ||
@@ -5,0 +5,0 @@ "main": "jwt.js", |
@@ -344,2 +344,4 @@ # fastify-jwt | ||
const fastify = require('fastify')() | ||
const jwt = require('fastify-jwt') | ||
const request = require('request') | ||
@@ -384,3 +386,3 @@ fastify.register(jwt, { | ||
if (err) fastify.log.error(err) | ||
fastify.log.info(`JWT token is ${body}`) | ||
fastify.log.info(`JWT token is ${body.token}`) | ||
@@ -392,3 +394,3 @@ // verify JWT | ||
'Content-Type': 'application/json', | ||
authorization: 'Bearer ' + sign.token | ||
authorization: 'Bearer ' + body.token | ||
}, | ||
@@ -399,3 +401,3 @@ uri: 'http://localhost:' + fastify.server.address().port + '/verify', | ||
if (err) fastify.log.error(err) | ||
fastify.log.info(`JWT verified. Foo is ${body.bar}`) | ||
fastify.log.info(`JWT verified. Foo is ${body.foo}`) | ||
}) | ||
@@ -402,0 +404,0 @@ }) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
73644
429