Issue #30 : Keep the username in localStorage, so that the user does not have to type it again in case his session has expired

+ also fill the login form with the localStorage values when the user chooses to logout
This commit is contained in:
mossroy 2014-08-06 15:22:59 +02:00
parent 3f75c49e3e
commit b2f319af71
2 changed files with 20 additions and 2 deletions

View file

@ -168,9 +168,8 @@ App.prototype.gotUnreadFeeds = function(new_articles) {
// user to login again if it is the case.
// This can happen with TT-RSS backend
if (new_articles.error && new_articles.error === "NOT_LOGGED_IN") {
$("#url").value = localStorage.server_url;
$("#login form").backend[0].checked = true;
alert("Your TinyTinyRSS session has expired. Please login again");
this.login.fillLoginFormFromLocalSotrage();
this.login.log_in();
}
else {