Commit 9883add2 authored by Vincent Bechu's avatar Vincent Bechu Committed by Eteri

erp5_officejs: remove service worker setting storage and application cache on bootloader

parent c110e73c
<!DOCTYPE html>
<html manifest="${application_appcache}">
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
......
......@@ -241,7 +241,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>958.11494.19014.6587</string> </value>
<value> <string>958.44234.50599.921</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -259,7 +259,7 @@
</tuple>
<state>
<tuple>
<float>1490198316.47</float>
<float>1492159460.13</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -5,13 +5,7 @@ var repair = false;
ProgressEvent, console) {
"use strict";
var serviceWorker_setting_storage = jIO.createJIO({
type: "uuid",
sub_storage: {
type: "indexeddb",
database: "serviceWorker_settings"
}
}), remote_storage = {
var remote_storage = {
type: "erp5",
url: window.location.origin +
window.location.pathname + "hateoasnoauth",
......@@ -149,7 +143,6 @@ var repair = false;
}
})
.push(undefined, function (error) {
console.log(error);
if (error instanceof ProgressEvent) {
if (gadget.props.sub === undefined) {
window.location.pathname += gadget.props.version_url;
......@@ -183,30 +176,27 @@ var repair = false;
document.querySelector("base")
);
}
navigator.serviceWorker.onerror = function (event) {
console.log(event);
};
return navigator.serviceWorker.register(
"gadget_officejs_bootloader_serviceworker.js",
{"scope": gadget.props.version_url }
);
"gadget_officejs_bootloader_serviceworker.js",
{"scope": gadget.props.version_url}
);
})
.push(function (registration) {
if (registration.installing) {
gadget.props.serviceWorker = registration.installing;
} else if (registration.waiting) {
gadget.props.serviceWorker = registration.waiting;
} else if (registration.active) {
gadget.props.serviceWorker = registration.active;
}
});
if (registration.installing) {
gadget.props.serviceWorker = registration.installing;
} else if (registration.waiting) {
gadget.props.serviceWorker = registration.waiting;
} else if (registration.active) {
gadget.props.serviceWorker = registration.active;
}
});
})
.declareService(function () {
var gadget = this;
function redirect() {
window.location.href = gadget.props.redirect_url;
window.location.pathname += gadget.props.version_url;
}
if (navigator.serviceWorker === undefined) {
......
......@@ -236,7 +236,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>958.34399.34294.34662</string> </value>
<value> <string>958.43127.34376.48742</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -254,7 +254,7 @@
</tuple>
<state>
<tuple>
<float>1491570174.38</float>
<float>1492093057.34</float>
<string>UTC</string>
</tuple>
</state>
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment