Skip to content
This repository has been archived by the owner on Oct 25, 2022. It is now read-only.

invalid phone number #5

Open
idkjs opened this issue Aug 18, 2019 · 0 comments
Open

invalid phone number #5

idkjs opened this issue Aug 18, 2019 · 0 comments

Comments

@idkjs
Copy link

idkjs commented Aug 18, 2019

Issue: aws-amplify/amplify-js#3868 (comment)

I have deployed using the click to deploy button.

While trying to sign in i get this error:

error signing up:  
Object { code: "InvalidParameterException", name: "InvalidParameterException", message: "Invalid phone number format." }

I get this whether the format is +1 999-999-9999 or 999-999-999 which should work if I am reading the following correctly:

    composePhoneNumber(dial_code, phone_line_number) {
        return `${dial_code || '+1'}${phone_line_number.replace(/[-()]/g, '')}`;
    }

https://github.com/aws-amplify/amplify-js/blob/ece0b229441357b754615052393e09bf8ecf6894/packages/aws-amplify-react/src/Auth/PhoneField.jsx#L25-L27

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant