keep localStorage tidier
This commit is contained in:
Родитель
6cb962252b
Коммит
94d0f95530
|
@ -49,13 +49,13 @@ module TDev
|
||||||
|
|
||||||
if (window.localStorage["lastExceptionMessage"]) {
|
if (window.localStorage["lastExceptionMessage"]) {
|
||||||
var msg = window.localStorage["lastExceptionMessage"];
|
var msg = window.localStorage["lastExceptionMessage"];
|
||||||
window.localStorage["lastExceptionMessage"] = "";
|
window.localStorage.removeItem("lastExceptionMessage");
|
||||||
if (TDev.Browser.EditorSettings.widgets().notifyAppReloaded)
|
if (TDev.Browser.EditorSettings.widgets().notifyAppReloaded)
|
||||||
upd = div("app-updated", lf("Something went wrong and we reloaded the app"));
|
upd = div("app-updated", lf("Something went wrong and we reloaded the app"));
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!upd && window.localStorage["appUpdated"]) {
|
if (!upd && window.localStorage["appUpdated"]) {
|
||||||
window.localStorage["appUpdated"] = "";
|
window.localStorage.removeItem("appUpdated");
|
||||||
if (dbg)
|
if (dbg)
|
||||||
upd = div("app-updated", lf("The TouchDevelop app has been updated."));
|
upd = div("app-updated", lf("The TouchDevelop app has been updated."));
|
||||||
}
|
}
|
||||||
|
|
|
@ -260,7 +260,7 @@
|
||||||
this.updateIsWaiting = false;
|
this.updateIsWaiting = false;
|
||||||
tick(Ticks.appUpdate);
|
tick(Ticks.appUpdate);
|
||||||
window.localStorage["appUpdated"] = "1";
|
window.localStorage["appUpdated"] = "1";
|
||||||
window.localStorage["lastForcedUpdate"] = "";
|
window.localStorage.removeItem("lastForcedUpdate");
|
||||||
window.location.reload();
|
window.location.reload();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
|
@ -2650,7 +2650,7 @@ module TDev{
|
||||||
{
|
{
|
||||||
var b = window.localStorage["storedBug"];
|
var b = window.localStorage["storedBug"];
|
||||||
if (b) {
|
if (b) {
|
||||||
window.localStorage["storedBug"] = "";
|
window.localStorage.removeItem("storedBug");
|
||||||
try {
|
try {
|
||||||
sendErrorReport(JSON.parse(b));
|
sendErrorReport(JSON.parse(b));
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
|
|
Загрузка…
Ссылка в новой задаче