Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is it a false report for error 'passport.initialize() middleware not in use' #24

Open
flight9 opened this issue Sep 28, 2018 · 7 comments

Comments

@flight9
Copy link

flight9 commented Sep 28, 2018

While I integrate feathers oauth2 with this passport-wechat, and visit http://localhost:3035/auth/wechat I got error 'passport.initialize() middleware not in use'.
I check this error is from line 56 in passport-wechat lib/strategy:

if (!req._passport) {
  return this.error(new Error('passport.initialize() middleware not in use'));
}

and why req._passport is undefined?

versions

"@feathersjs/authentication": "^2.1.7",
"@feathersjs/authentication-jwt": "^2.0.0",
"@feathersjs/authentication-local": "^1.1.0",
"@feathersjs/authentication-oauth2": "^1.2.4"
"passport-wechat": "^2.0.4"

Finally I found If I comment the above line, it can still work correctly. So is that a false report error?

@peveuve
Copy link

peveuve commented Feb 28, 2019

Any news on this issue? we have the exact same one.

@hui9464
Copy link

hui9464 commented Mar 30, 2021

同样问题

@shadows-nhp
Copy link

Any news on this issue? we have the exact same one.

did you resolve it?

@shadows-nhp
Copy link

同样问题

解决了吗

@hui9464
Copy link

hui9464 commented Apr 3, 2024

相同的问题

解决了吗

自己重写一个,他这个库,就是有这个问题,而且没人维护了

@shadows-nhp
Copy link

相同的问题

解决了吗

自己重写一个,他这个库,就是有这个问题,而且没人维护了

老板,可以共享一下么

@hui9464
Copy link

hui9464 commented Apr 4, 2024

相同的问题

解决了吗

自己重写一个,他这个库,就是有这个问题,而且没人维护了

老板,可以共享一下么

你参考下,我随便搞了下,后面没怎么用。https://github.com/hui9464/passport-wechatapp

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

No branches or pull requests

4 participants