Open saneera opened 6 years ago
Could you provide a link to your code? Thanks
Sorry, I need more context. Could you link to a repo?
I think it has to do with your custom use of types in the lambda function. E.g., you import Callback
from aws-lambda
, whereas I use
export type Callback = (err?: Error | string, data?: any) => void;
Perhaps try to reuse the same types first, and then see where it fails if you'd like to start using alternative types.
I tried but still fails
I think it has to do strict
type checking in your tsconfig.json
, which prevents undefined
and null
from being used interchangeably. I did plan to update the code to be strict at some point, but not sure I have time for that now, unfortunately. I'd recommend either disabling strict type checking, or tracing down the errors where the output of one of the helper functions can be undefined. The error seems to be in this line https://github.com/saneera/presignup/blob/b287636401c492963e5ee0624bb9f07bdc8ad4ca/serverless/presignup/my_modules/pre-signup-lambda-integration/pre-signup-integration-request-function.ts#L24
Thanks very much I did the change working fine it created two users google and native user with same sub first time not logged in second time its working fine its that normal ?
Thanks for your help again
Glad to hear it! I started experiencing the same problem ~ a month after writing that code. It appears to be an issue with AWS Cognito Auth service that's not yet resolved: https://forums.aws.amazon.com/thread.jspa?messageID=814706
Hi I m going to integrate only pre sign up handler and I m new to node and typescript