Status-react: Unknown in Profile and "null is not an object" at attempt to log out after log out from offline

Created on 21 Aug 2019  路  6Comments  路  Source: status-im/status-react

Description

Type: Bug
Summary: when log out without network, after login instead of username "Unknown" is shown without user picture and also at attempt to log out "null is not an object(evaluating 'n.toLowerCase''"
Network settings are empty for such users.

Expected behavior

Can log out;
usename userpicture is valid;
network settings are shown

Actual behavior

photo_2019-08-21 16 00 18

Reproduction

  • Open Status
  • Create new account
  • Turn on Airplane mode
  • Log out
  • Login
  • Turn off Airplane mode

Additional Information

  • Status version: nightly 21/08/2019
  • Operating System: Android, iOS

Logs

status_logs.zip

bug high-priority

Most helpful comment

@bitsikka thanks a lot!
Tested both scenarios and can't reproduce anymore.

All 6 comments

cc @yenda @rachelhamlin

The same behavior is reproducible when you create account -> switch to Ropsten -> create new account.

@churik do you mean create account or create multiaccount?

I came across "Unknown in Profile" part of the issue doing simply this

  • create account and log in (profile behaves as it should)
  • log out and log back in
  • scroll down in profile to reveal profile header in toolbar position (profile shows blank pic shifted down with "Unknown" for name

I found it while testing/iterating/developing PR #8825 , bothered me very much since I am partly responsible :), investigated and found the cause, fixed it in latest push.

It happened because subscription :multiaccount is null briefly when logging in. When it got populated millseconds later, the header-in-toolbar component that subscribes it was not setup to re-render.

Please note, while this is related, and "part" of the original issue seems to be fixed in that PR, other parts of the original issue have not been attended in the PR.

Legend @bitsikka!!

@churik can you confirm that this is fixed by PR 8825 and close if so?

@bitsikka thanks a lot!
Tested both scenarios and can't reproduce anymore.

Was this page helpful?
0 / 5 - 0 ratings