From 5bd63db63998e66a3a0b38e1f143503222b6ea9d Mon Sep 17 00:00:00 2001 From: Alexander Mills Date: Mon, 26 Oct 2015 15:23:06 -0700 Subject: [PATCH 1/2] Update README.md need to add this var BasicStrategy = require('passport-http').BasicStrategy thx --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 57a6f30..302d383 100644 --- a/README.md +++ b/README.md @@ -20,6 +20,8 @@ The HTTP Basic authentication strategy authenticates users using a userid and password. The strategy requires a `verify` callback, which accepts these credentials and calls `done` providing a user. +var BasicStrategy = require('passport-http').BasicStrategy + passport.use(new BasicStrategy( function(userid, password, done) { User.findOne({ username: userid }, function (err, user) { From c83ad720728b0a3fdef2565f51e0821bf219b557 Mon Sep 17 00:00:00 2001 From: Alexander Mills Date: Wed, 3 Oct 2018 14:04:15 -0700 Subject: [PATCH 2/2] added necessary import added necessary import --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 302d383..4e1b20b 100644 --- a/README.md +++ b/README.md @@ -20,7 +20,7 @@ The HTTP Basic authentication strategy authenticates users using a userid and password. The strategy requires a `verify` callback, which accepts these credentials and calls `done` providing a user. -var BasicStrategy = require('passport-http').BasicStrategy +const {BasicStrategy} = require('passport-http'); passport.use(new BasicStrategy( function(userid, password, done) {