diff --git a/react/features/base/jwt/functions.js b/react/features/base/jwt/functions.js index 54fe75030..1d398c85a 100644 --- a/react/features/base/jwt/functions.js +++ b/react/features/base/jwt/functions.js @@ -24,5 +24,5 @@ export function parseJWTFromURLParams(url: URL = window.location) { export function getJwtName(state: Object) { const { user } = state['features/base/jwt']; - return user?.name || ''; + return user?.name; } diff --git a/react/features/base/settings/middleware.js b/react/features/base/settings/middleware.js index 90bcd6593..89c90b774 100644 --- a/react/features/base/settings/middleware.js +++ b/react/features/base/settings/middleware.js @@ -135,9 +135,11 @@ function _maybeUpdateDisplayName({ dispatch, getState }) { if (hasJwt) { const displayName = getJwtName(state); - dispatch(updateSettings({ - displayName - })); + if (displayName) { + dispatch(updateSettings({ + displayName + })); + } } }