Prisma-care / mobile-app

Color your memories
https://prisma.care
101 stars 3 forks source link

Login automatically expires after a while #130

Closed fritsbits closed 6 years ago

fritsbits commented 6 years ago

After not using the app for a day or so, I end up on an empty album overview. Need to log out and in again.

th0rgall commented 6 years ago

Confirmed, I had the same issue.

fritsbits commented 6 years ago

One day later and I'm still logged in! It seems to work.

Can you merge it in?

Before releasing a new version I'd like to add some more value. Will look into adding extra trigger questions.

fritsbits commented 6 years ago

It happened again. Logged out again. How about you @th0rgall ?

th0rgall commented 6 years ago

@fritsbits If we don't release now, I guess it only makes sense to merge in the branch if the error is confirmed to be fixed.

I think I fixed a login safeguard @oxnoctisxo put in. I didn't work anymore because it checked literal error messages that appear to have changed in the backend.

It's a clutter to test, but if it worked before it should be working now. We'll know tomorrow!

And I mean working: not redirecting to an empty album page, but to the login page when the token expires. No perma-login yet.

@MichielLeyman am I correct in assuming that if we don't want the user to experience an auto log out, we should either

  1. provide tokens without expiration (no go?)
  2. safely cache the login credentials on the device & login again in the background