Skip to content
This repository has been archived by the owner on Apr 5, 2024. It is now read-only.

Commit

Permalink
Merge pull request #258 from salarelv/master
Browse files Browse the repository at this point in the history
Checks correctly routes auth strategy
  • Loading branch information
hueniverse committed Sep 15, 2019
2 parents f455587 + 0d93c8c commit 61458a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/plugin.js
Expand Up @@ -42,7 +42,7 @@ internals.hawk = function (server, options) {
return h.unauthenticated(err, credentials ? { credentials, artifacts } : undefined);
}

if (request.route.settings.auth.payload) {
if (server.auth.lookup(request.route).payload) {
request.events.once('peek', (chunk) => {

const payloadHash = Crypto.initializePayloadHash(request.auth.credentials.algorithm, request.headers['content-type']);
Expand Down

0 comments on commit 61458a5

Please sign in to comment.