diff options
Diffstat (limited to 'webapp/components/rename_channel_modal.jsx')
-rw-r--r-- | webapp/components/rename_channel_modal.jsx | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/webapp/components/rename_channel_modal.jsx b/webapp/components/rename_channel_modal.jsx index 8d36e15c7..6d7156b51 100644 --- a/webapp/components/rename_channel_modal.jsx +++ b/webapp/components/rename_channel_modal.jsx @@ -139,6 +139,17 @@ export class RenameChannelModal extends React.Component { } else if (channel.display_name.length > Constants.MAX_CHANNELNAME_LENGTH) { state.displayNameError = formatMessage(holders.maxLength, {maxLength: Constants.MAX_CHANNELNAME_LENGTH}); state.invalid = true; + } else if (channel.display_name.length < Constants.MIN_CHANNELNAME_LENGTH) { + state.displayNameError = ( + <FormattedMessage + id='rename_channel.minLength' + defaultMessage='Channel name must be {minLength, number} or more characters' + values={{ + minLength: Constants.MIN_CHANNELNAME_LENGTH + }} + /> + ); + state.invalid = true; } else { state.displayNameError = ''; } |