-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
refactor signup attributes as objects #79
Conversation
Codecov Report
@@ Coverage Diff @@
## master #79 +/- ##
==========================================
+ Coverage 92.03% 92.04% +0.01%
==========================================
Files 51 51
Lines 2260 2263 +3
Branches 459 460 +1
==========================================
+ Hits 2080 2083 +3
Misses 171 171
Partials 9 9
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- up unit test coverage
- change arg name
- change attribute type to object
- attribute object k = attribute Name
- fix conflicts
@@ -21,7 +21,7 @@ export default class AuthClass { | |||
* @param {Object} attributeList - Other attributes | |||
* @return - A promise resolves callback data if success | |||
*/ | |||
signUp(username: string, password: string, email: string, phone_number: string): Promise<any>; | |||
signUp(username: string, password: string, email?: string | Array<Object>, phone_number?: string): Promise<any>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change argument name 'email' to 'attributes' and continue backwards compatibility check below, also update function comment
public signUp(username: string, password: string, email: string, phone_number: string): Promise<any> { | ||
public signUp(username: string, | ||
password: string, | ||
email?: string|Array<Object>, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update attributes (email) argument to be an object {} allowing k/v pairs for where k is attribute name
What about validation data? Why isn't it included? |
Is this feature available in aws-amplify-react now ? |
This pull request has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs. Looking for a help forum? We recommend joining the Amplify Community Discord server |
No description provided.