diff --git a/HISTORY.md b/HISTORY.md index ec3b57e957..33bac078de 100755 --- a/HISTORY.md +++ b/HISTORY.md @@ -3,6 +3,7 @@ ## v4.2.2.9 ### 2018-11-29 * GUI: prepared release +* GUI: fixed offline version (avoid sessionStorage access) ### 2018-11-28 * Objects: added special checks to make imporing text-based files into vars easier in Windows diff --git a/src/gui.js b/src/gui.js index 499d171b12..b58864e50a 100644 --- a/src/gui.js +++ b/src/gui.js @@ -296,12 +296,14 @@ IDE_Morph.prototype.openIn = function (world) { } } - if (!sessionStorage.username) { - // check whether login should persist across browser sessions - this.cloud.initSession(initUser); - } else { - // login only persistent during a single browser session - this.cloud.checkCredentials(initUser); + if (location.protocol !== 'file:') { + if (!sessionStorage.username) { + // check whether login should persist across browser sessions + this.cloud.initSession(initUser); + } else { + // login only persistent during a single browser session + this.cloud.checkCredentials(initUser); + } } this.buildPanes();