diff options
-rw-r--r-- | src/org/traccar/api/resource/SessionResource.java | 2 | ||||
-rw-r--r-- | web/app/view/LoginController.js | 6 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/org/traccar/api/resource/SessionResource.java b/src/org/traccar/api/resource/SessionResource.java index ae2c919e9..49670c1f9 100644 --- a/src/org/traccar/api/resource/SessionResource.java +++ b/src/org/traccar/api/resource/SessionResource.java @@ -41,7 +41,7 @@ public class SessionResource extends BaseResource { public static final String USER_ID_KEY = "userId"; public static final String USER_COOKIE_KEY = "user"; - public static final String PASS_COOKIE_KEY = "pass"; + public static final String PASS_COOKIE_KEY = "password"; @javax.ws.rs.core.Context private HttpServletRequest request; diff --git a/web/app/view/LoginController.js b/web/app/view/LoginController.js index 47fae59f9..8beef1e04 100644 --- a/web/app/view/LoginController.js +++ b/web/app/view/LoginController.js @@ -40,9 +40,9 @@ Ext.define('Traccar.view.LoginController', { callback: function (options, success, response) { Ext.getBody().unmask(); if (success) { - if (this.lookupReference('rememberMeField').getValue()) { + if (this.lookupReference('rememberField').getValue()) { Ext.util.Cookies.set('user', this.lookupReference('userField').getValue(), Ext.Date.add(new Date(), Ext.Date.YEAR, 1)); - Ext.util.Cookies.set('pass', this.lookupReference('passwordField').getValue(), Ext.Date.add(new Date(), Ext.Date.YEAR, 1)); + Ext.util.Cookies.set('password', this.lookupReference('passwordField').getValue(), Ext.Date.add(new Date(), Ext.Date.YEAR, 1)); } Traccar.app.setUser(Ext.decode(response.responseText)); this.fireViewEvent('login'); @@ -56,7 +56,7 @@ Ext.define('Traccar.view.LoginController', { logout: function () { Ext.util.Cookies.clear('user'); - Ext.util.Cookies.clear('pass'); + Ext.util.Cookies.clear('password'); Ext.Ajax.request({ scope: this, method: 'DELETE', |