PLT-3698 Improved handling of colons around a custom emoji's name (#3676)
Этот коммит содержится в:
коммит произвёл
Joram Wilander
родитель
564dffec35
Коммит
13b7368f9d
@@ -56,6 +56,11 @@ export default class AddEmoji extends React.Component {
|
|||||||
name: this.state.name.trim().toLowerCase()
|
name: this.state.name.trim().toLowerCase()
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// trim surrounding colons if the user accidentally included them in the name
|
||||||
|
if (emoji.name.startsWith(':') && emoji.name.endsWith(':')) {
|
||||||
|
emoji.name = emoji.name.substring(1, emoji.name.length - 1);
|
||||||
|
}
|
||||||
|
|
||||||
if (!emoji.name) {
|
if (!emoji.name) {
|
||||||
this.setState({
|
this.setState({
|
||||||
saving: false,
|
saving: false,
|
||||||
|
|||||||
Ссылка в новой задаче
Block a user