From f20e2d65c3aa5ef7eaa247702757f7d05455ffbd Mon Sep 17 00:00:00 2001 From: Juan Ferrer Toribio Date: Fri, 12 Jan 2018 12:35:58 +0100 Subject: [PATCH] Login bug solved (history.back) --- debian/changelog | 2 +- js/hedera/app.js | 15 +++++++++------ js/hedera/login.js | 2 +- package.json | 2 +- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/debian/changelog b/debian/changelog index f96c6c4a..fe467a77 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,4 +1,4 @@ -hedera-web (1.405.64) stable; urgency=low +hedera-web (1.405.65) stable; urgency=low * Initial Release. diff --git a/js/hedera/app.js b/js/hedera/app.js index cd6ce000..7713cf2e 100644 --- a/js/hedera/app.js +++ b/js/hedera/app.js @@ -42,13 +42,16 @@ module.exports = new Class ,_onLogin: function () { this._freeLogin (); + + if (this._gui) + return; var gui = this._gui = new Gui ({conn: this._conn}); gui.on ('logout', this._onLogout, this); gui.show (); } - ,_onLogout: function (gui) + ,_onLogout: function () { this.clearAutoLogin (); this._freeGui (); @@ -100,7 +103,7 @@ module.exports = new Class this._gui.logout (); } - ,_newVersion: function (error) + ,_newVersion: function () { if (this.ignoreVersion) return; @@ -126,10 +129,10 @@ module.exports = new Class Htk.Toast.showError (_('Something went wrong')); var params = { - 'file': error.fileName - ,'line': error.lineNumber - ,'message': error.message - ,'stack': error.stack + file: error.fileName + ,line: error.lineNumber + ,message: error.message + ,stack: error.stack }; this._conn.send ('core/log', params); } diff --git a/js/hedera/login.js b/js/hedera/login.js index 575b3095..3bfc4368 100644 --- a/js/hedera/login.js +++ b/js/hedera/login.js @@ -44,7 +44,7 @@ module.exports = new Class this.$('spinner').stop (); } - ,show: function (firstLogin) + ,show: function () { document.body.appendChild (this.node); diff --git a/package.json b/package.json index 892174c5..5e071a3e 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "hedera-web", - "version": "1.405.64", + "version": "1.405.65", "description": "Verdnatura web page", "license": "GPL-3.0", "repository": {