title: Express-jwt not setting req.user when used with blacklist revoke function
body: <p>I tried user authentication REST API using express-jwt and logout using express-jwt-blacklist. But when I started using blacklist revoke function I get express-jwt is not setting req.user below is my code:</p>
  
  <pre><code>const express = require("express")
  var expressJwt = require('express-jwt');
  var blacklist = require('express-jwt-blacklist');
  const bodyParser = require('body-parser')
  const app = express()
  app.locals.authSecret="MySuperSecretKey"
  app.use(bodyParser.json())
  app.use(bodyParser.urlencoded({
      extended: true
  }))
  
  
  app.use(expressJwt({ 
      secret: app.locals.authSecret,
      isRevoked: blacklist.isRevoked,//When I remove this option details is working
      credentialsRequired: false
  }).unless(function(r) {
      allowed = [
          '/user/signup',
          '/user/login'
      ]
  
      return allowed.indexOf(r.originalUrl) &gt;= 0
  }))
  
  app.use(function (err, req, res, next) {
      if (err.name === 'UnauthorizedError') {
          res.json({success:false,error:"Unauthorized access token"})
          return;
      }
      next()
    });
  app.get('user/login',function(req,res){
      var username =  sanitizer.sanitize(req.body.username);
      var password = sanitizer.sanitize(req.body.password);
      User.findOne({username:username}, function(err,docs){
          if(err)
              res.json({success:false,error:"Error in database connection"})
      }).cursor().on("data",function(doc)
      {
          bcrypt.compare(password, doc.password, function(err, same) {
              if(err || !same) {
                  res.json({success:false,error:"Wrong username or password"})
              } else {
                  var userId = doc._id
                  req.user = userId
                  console.log(req.user)
                  res.json({success:true,authToken: jwt.sign({id: userId},req.app.locals.authSecret, {expiresIn: '10d'})})    
              }
          })
      })          
  })
  
  //Get user details by passing JWT Token in header
  app.get('user/details',function(req,res){
      if(req.user) {
          User.findOne({_id:req.user.id}, function(err,docs){
              if(err) 
                  res.json({success:false,error:"Error in database connection"})
          }).cursor().on("data",function(doc)
          {
              var user={
                  firstName:doc.firstName,
                  lastName:doc.lastName,
                  username:doc.username,
                  gender:doc.gender,
                  email:doc.email,
                  mobile:doc.mobile,        
              }
              res.json({success:true,data:user})
          })
  } else {
      res.json({success:false,error:"Unauthorized access"})
  }  
  })
  
  //Logout
  app.get('user/logout',function(req,res){    
          blacklist.revoke(req.headers.authorization)
          res.json({success:true,message:"You have been successfully logged out"})
  
      })
  
  app.listen(8080, function() {
      console.log("Started server at 8080..")
  });
  </code></pre>
  
  <p>The code works fine till login. But when I call user/details using JWT Token I get the response as "Unauthorized token" ( the req.user is not set)</p>