remixz / umi

📺 Watch Crunchyroll together, and more

Home Page:https://umi.party

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Session being lost upon reload/open in new tab

FelixGrafschmidt opened this issue · comments

If i reload the page or open a page in a new tab, my session is lost. From what I can tell the session is saved in the vuex store, maybe this could be done server-side to allow users to keep their session over mutliple tabs.

Alternatively, if no server is available, this could also be done via localStorage.

I resolved the issue on my local fork with the above fix. if you could test it as well it would be great

If i reload the page or open a page in a new tab, my session is lost. From what I can tell the session is saved in the vuex store, maybe this could be done server-side to allow users to keep their session over mutliple tabs.

Also, this is a pretty bad idea, Sessions can be used to do all kind of actions on crunchyroll, including giving out the premium-trials etc. I'd rather have that not stored on the server. Umi already uses the localStorage for this, which is perfectly fine. It's just that "refreshing" the page, triggers a logout procedure because of a missing or unset key in the local storage.

I can confirm that your fork does fix the issue. I am however not familiar with this project's general structure, therefore I cannot with authority say whether or not this does not lead to any other problems.

In that case we could also change the check to be a check for undefined. since the value gets set to null by the response of the login request.