Skip to content

Allow built-in token middleware to run repeatedly [back-port to 2.x] - #2204

Merged
bajtos merged 1 commit into
2.xfrom
backport/pr2108
Apr 6, 2016
Merged

Allow built-in token middleware to run repeatedly [back-port to 2.x]#2204
bajtos merged 1 commit into
2.xfrom
backport/pr2108

Conversation

@bajtos

@bajtos bajtos commented Apr 6, 2016

Copy link
Copy Markdown
Member

Back-port two new options that were recently added to master branch (3.x series):

  • When enableDoublecheck is true, the middleware will run
    even if a previous middleware has already set req.accessToken
    (possibly to null for anonymous requests)
  • When overwriteExistingToken is true (and enableDoublecheck too),
    the middleware will overwrite req.accessToken set by a previous
    middleware instances.

See #2108
/cc @benkroeger

Add two new options:

  - When `enableDoublecheck` is true, the middleware will run
    even if a previous middleware has already set `req.accessToken`
    (possibly to `null` for anonymous requests)

  - When `overwriteExistingToken` is true (and `enableDoublecheck` too),
    the middleware will overwrite `req.accessToken` set by a previous
    middleware instances.
@bajtos bajtos added the #review label Apr 6, 2016
@bajtos
bajtos merged commit 4678cb4 into 2.x Apr 6, 2016
@bajtos
bajtos deleted the backport/pr2108 branch April 6, 2016 14:06
@bajtos bajtos removed the #review label Apr 6, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant