diff --git a/app/soapbox/reducers/auth.js b/app/soapbox/reducers/auth.js index 18d7d1219..c3cf164ab 100644 --- a/app/soapbox/reducers/auth.js +++ b/app/soapbox/reducers/auth.js @@ -143,10 +143,14 @@ const reload = state => { } }; +// `me` is a user ID string +const validMe = state => { + const me = state.get('me'); + return typeof me === 'string' && me !== '_legacy'; +}; + // `me` has changed from one valid ID to another const userSwitched = (oldState, state) => { - const validMe = state => typeof state.get('me') === 'string'; - const stillValid = validMe(oldState) && validMe(state); const didChange = oldState.get('me') !== state.get('me');