Hi,
I'm using your passport-nylas and I have some trouble getting access to the state param in my verifier callback. (https://docs.nylas.com/reference#oauthauthorize)
Basically, I'm passing the state parameter to Nylas, like this .../auth/nylas?state=something and I have it back from Nylas inside req.query along with code.
What do you think about passing the the entire request object + the email instead of only the email to the verifier callback? It would be a breaking change but I don't have any better idea :)
Hi, I'm using your passport-nylas and I have some trouble getting access to the
state
param in my verifier callback. (https://docs.nylas.com/reference#oauthauthorize) Basically, I'm passing the state parameter to Nylas, like this.../auth/nylas?state=something
and I have it back from Nylas insidereq.query
along withcode
.Checking the source code of your library I've noticed that the 'verify' callback is called only with the email coming from the oAuth token request: https://github.com/ewdave/passport-nylas/blob/master/nylas-strategy.js#L176 so the entire
request
object is not available inside the verifier callback.What do you think about passing the the entire
request
object + the email instead of only the email to the verifier callback? It would be a breaking change but I don't have any better idea :)Thanks a lot and keep up the good work!