Commit 5c0a852e authored by Jérome Perrin's avatar Jérome Perrin

web_renderjs_ui: update comments about the reason for not using cache.addAll

The main reason for not using cache.addAll was to fill the cache as a low
priority task, not to generate too much traffic, the safari compatibility
was secondary. Now that safari seems to support cache.addAll, remove the
comment about safari.
parent 9b38dca8
Pipeline #13133 failed with stage
in 0 seconds
......@@ -21,20 +21,19 @@
event.waitUntil(
caches.open(CACHE_NAME)
.then(function (cache) {
// Add all offline dependencies to the cache, one by one, to not
// hammer zopes.
var promise = Promise.resolve();
function append(url_to_cache) {
promise = promise
.then(function () {
// Use cache.add because safari does not support cache.addAll.
return cache.add(url_to_cache);
});
}
len = required_url_list.length;
for (i = 0; i < len; i += 1) {
// Add all offline dependencies to the cache
// One by one, to not hammer zopes
append(required_url_list[i]);
}
return promise;
......
......@@ -256,7 +256,7 @@
</tuple>
<state>
<tuple>
<float>1581435049.45</float>
<float>1581435059.45</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