title: Flask-JWT-Extended: @jwt_refresh_token_required annotation does not work
body: <p>I have a login resource (<code>/login</code> endpoint), following Oleg Agapov's <a href="https://codeburst.io/jwt-authorization-in-flask-c63c1acf4eeb" rel="nofollow noreferrer">tutorial</a>:</p>
  
  <pre><code>class UserLogin(Resource):
      def post(self):
          data = parser.parse_args()
          current_user = User.find_by_email(data['email'])
  
          if not current_user:
              return {'message': 'User {} doesn\'t exist'.format(data['email'])}
  
          if User.verify_hash(data['password'], current_user.password):
              refresh_token = create_refresh_token(identity = data['email'])
              return {
                  'message': 'Logged in as {}'.format(current_user.email),
                  'refresh_token': refresh_token
                  }
          else:
              return {'message': 'Wrong credentials'}
  </code></pre>
  
  <p>Calling this endpoint with correct credentials I do get the response back:</p>
  
  <pre><code>{
    "message": "Logged in as test@gmail.com",
    "refresh_token": "eyJ0eXAiOiJKV1.............TheVeryLongRefreshTokenString...........JfkRatZ2NaA72Tl4b9C4-e3d6kXA"
  }
  </code></pre>
  
  <p>Now, I have a test resource on the <code>/secret</code> endpoint:</p>
  
  <pre><code>class SecretResource(Resource):
      @jwt_refresh_token_required
      def get(self):
          return {
              'answer': 42
          }
  </code></pre>
  
  <p>Calling this endpoint with the <code>refresh_token</code> included as a Bearer header in the request should return:</p>
  
  <pre><code>{
     "answer": 42
  }
  </code></pre>
  
  <p>Without the <code>@jwt_refresh_token_required</code> annotation (without sending any tokens) this is exactly what I get. But I need the annotation to secure my endpoint with some token requirement. </p>
  
  <p>Only it doesn't work. Using the <code>Authentication : Bearer *Refresh_Token*</code> header I only get:</p>
  
  <pre><code>{
     "message": "Internal Server Error"
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/EX9zV.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/EX9zV.png" alt="enter image description here"></a></p>
  
  <p>I know <code>access_token</code> should be used for this, but I did not wanted it for its 15 minutes expiration time. I don't see why would it be a problem since we are doing the same to refresh the <code>access_token</code> itself with an endpoint requiring a <code>refresh_token</code>. I can be wrong of course.</p>
  
  <p>This is the snippet from the <code>poject_folder</code> root folder's <code>__init__.py</code> where the revocation is checked:</p>
  
  <pre><code>@jwt.token_in_blacklist_loader
  def check_if_token_in_blacklist(decrypted_token):
      jti = decrypted_token['jti']
      return poject_folder.Model.RevokedTokenModel.is_jti_blacklisted(jti)
  </code></pre>
  
  <p>What am I missing here?</p>