passport-oauth2
passport-oauth2 copied to clipboard
Error in strict mode
I'm on io.js that is run with --use_strict
parameter. My script fails with the following error when trying to sign in with google OAuth2:
Error.captureStackTrace(this, arguments.callee);
^
TypeError: 'caller', 'callee', and 'arguments' properties may not be accessed on strict mode functions or the arguments objects for calls to them
at new InternalOAuthError (/Users/konstantintsabolov/dev/node-boilerplate/node_modules/passport-google-oauth/node_modules/passport-oauth/node_modules/passport-oauth2/lib/errors/internaloautherror.js:15:42)
As the error said, it's because of accessing arguments.callee
in the InternalOAuthError
constructor. Do you plan to refactor the code to make it strict-compatible?
+1, same error message. In strict mode via passport-google
.
Edit: I fixed it by updating my callback function arguments for the GoogleStrategy object. I realized I was using an old configuration which caused the error.
I have to take back what I said in the update of my last post. Actually the same error is now occurring in the Facebook plugin using oauth. This is causing me some major headaches because I can't get Facebook login to work. Strict mode is required for my software stack.
Any update on this? I have the same issue.