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

login callback #5

Open
sundyxfan opened this issue Dec 21, 2015 · 1 comment
Open

login callback #5

sundyxfan opened this issue Dec 21, 2015 · 1 comment

Comments

@sundyxfan
Copy link

passport.use(new qqStrategy({
    clientID: client_id,
    clientSecret: client_secret,
    callbackURL: "http://127.0.0.1:3000/auth/qq/callback"
  },
  function(accessToken, refreshToken, profile, done) {
   // TODO
    User.findOrCreate({ qqId: profile.id }, function (err, user) {
      return done(err, user);
    });
  }
));

什么时候执行TODO 部分

@dotku
Copy link

dotku commented Dec 21, 2015

有信息返回的时候

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

2 participants