-
Notifications
You must be signed in to change notification settings - Fork 26
Nuru/fix setting address #415
Nuru/fix setting address #415
Conversation
Examine how the validation and server handing is done in virtual account creation. |
@boris have thought as well also. But the problem is the server errors with regard to the address and the phone number are not specific. SO i think we have to use the front end . Example for address it returns something like. |
I wasn't that much against the validation itself, than the way we store it. |
@borisyankov have moved the error to the jsx/return method as suggested . One more thing to remember. Unlike the create account, here we do not have a server validation for phone number length. This feature is solely a front end validation on the binary.com itself. |
if (phone.length < 6) { | ||
this.setState({ phoneError: 'length' }); | ||
} else if (phone.match(/[a-z]/i)) { | ||
this.setState({ phoneError: 'allowed' }); |
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.
why set error to allowed
? or you actually want to remove error?
Hi,
Attached contained little validations that i think should enhance our SettingsAddress page as its done in binary.com for your perusal.