fix an err in oauth midware by xiaozhongliu · Pull Request #52 · node-modules/weibo · GitHub
Skip to content

fix an err in oauth midware#52

Open
xiaozhongliu wants to merge 1 commit into
node-modules:masterfrom
xiaozhongliu:patch-1
Open

fix an err in oauth midware#52
xiaozhongliu wants to merge 1 commit into
node-modules:masterfrom
xiaozhongliu:patch-1

Conversation

@xiaozhongliu

Copy link
Copy Markdown

when requesting /oauth/logout, the relevant if branch of "logoutPath" won't get reached.
because the url will match /oauth , the if branch of "loginPath" will intercept the execution.

when requesting /oauth/logout, the relevant if branch of "logoutPath" won't get reached.
because the url will match /oauth , the if branch of "loginPath" will intercept the execution.
@mention-bot

Copy link
Copy Markdown

@xiaozhongliu

Copy link
Copy Markdown
Author

@fengmk2 not able to add a reviewer, so @ you here :)

Comment thread lib/oauth_middleware.js

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's different here?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@fengmk2 using the original code, when you visit '/oauth/logout', login() gets called.

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.

3 participants