-
Notifications
You must be signed in to change notification settings - Fork 11.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
adding the ability to edit usernames #696
Conversation
I also removed a bunch of redspace near where I was working. Long empty lines make me cringe to see, can't help but remove. |
Just a little UI request. Maybe order Username / Password / Language ? |
Sure thing |
Added the username as a placeholder. |
Looks great! Thank you! |
Guys, update the username is not that simple. You need to use the method. There are a lot of checking and references that need o be updated together, not just the users collection. |
Need to call /packages/rocketchat-lib/server/methods/setUsername.coffee |
…n for the toaster to show up properly
Setting the username properly. Hopefully good enough! |
@engelgabriel updated, anything else missing? |
@soonahn Sorry for the confusion. I thought I had mentioned the use of Tested this out. (this time with actual messages to make sure those are still changed) Sorry oversight last time. :) LGTM i'll leave this for @engelgabriel though. :) |
@@ -11,7 +11,7 @@ Meteor.methods | |||
return username | |||
|
|||
if not /^[0-9a-zA-Z-_.]+$/.test username | |||
throw new Meteor.Error 'username-invalid' | |||
throw new Meteor.Error 'username-invalid', TAPi18next.t('project:Username_invalid', username) |
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 TAPi18next.t('project:Username_invalid', username)
?
The translation should not be done on the server side, as the client may be using a different language.
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.
Still new to Meteor, unsure which pieces fit where. I assumed the client data got passed down and translated then passed back up to the server.
Sorry! I'll read the docs better next time.
adding the ability to edit usernames
Addresses #695