Skip to content
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

Custom tokens must have between 0 and 12 characters #7672

Merged
merged 3 commits into from
Dec 21, 2019

Conversation

ggviana
Copy link
Contributor

@ggviana ggviana commented Dec 9, 2019

Custom token ui shouldn't show error when the a token symbol has exactly 12 characters

Fixes #7668

@Gudahtt
Copy link
Member

Gudahtt commented Dec 9, 2019

The intention was to limit token symbols to a maximum of 11 characters; the error message was just worded poorly.

While we could certainly consider increasing that limit, this doesn't fix the linked issue. If anything this makes the error message more misleading, as now the range given ("between 0 and 12") is exclusive on one end and inclusive on the other.

@whymarrh
Copy link
Contributor

whymarrh commented Dec 11, 2019

To follow-up to @Gudahtt's comment, we could maybe adjust the message to add a qualifier like so:

Symbol must be between 1 and 12 characters, inclusively.

Or even:

Symbol must be 11 characters or fewer.

@whymarrh
Copy link
Contributor

@ggviana do you want to try updating this PR? Let me know if I can help out.

@ggviana
Copy link
Contributor Author

ggviana commented Dec 20, 2019

@whymarrh I updated the error messages and provided the translations.
Please let me know if there's anything else I can do to fix this issue.

Copy link
Contributor

@whymarrh whymarrh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @ggviana! This looks good to me!

@whymarrh whymarrh merged commit 5bac055 into MetaMask:develop Dec 21, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Metamask says it only allows tokens with symbol between 0 and 12 chars, but doesn't allow 12 chars
3 participants