mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Fixing JS error (#6813)
* Fixing JS error * Fixing js error and storing issue
This commit is contained in:
@@ -107,7 +107,7 @@ export function sortChannelsByDisplayName(a, b) {
|
||||
const aDisplayName = getChannelDisplayName(a);
|
||||
const bDisplayName = getChannelDisplayName(b);
|
||||
|
||||
if (aDisplayName !== bDisplayName) {
|
||||
if (aDisplayName !== null && bDisplayName !== null && aDisplayName !== bDisplayName) {
|
||||
return aDisplayName.localeCompare(bDisplayName, locale, {numeric: true});
|
||||
}
|
||||
|
||||
|
||||
@@ -1011,7 +1011,7 @@ export function displayUsernameForUser(user) {
|
||||
return name;
|
||||
}
|
||||
|
||||
return null;
|
||||
return '';
|
||||
}
|
||||
|
||||
// Converts a file size in bytes into a human-readable string of the form '123MB'.
|
||||
|
||||
Reference in New Issue
Block a user