forked from mystiq/hydrogen-web
Merge pull request #578 from vector-im/fix-progressbar
Fix progressbar not working on attachment uploads
This commit is contained in:
commit
c47f872f6f
1 changed files with 8 additions and 1 deletions
|
@ -69,7 +69,14 @@ async function purgeOldCaches() {
|
|||
}
|
||||
|
||||
self.addEventListener('fetch', (event) => {
|
||||
event.respondWith(handleRequest(event.request));
|
||||
/*
|
||||
service worker shouldn't handle xhr uploads because otherwise
|
||||
the progress events won't fire.
|
||||
This has to do with xhr not being supported in service workers.
|
||||
*/
|
||||
if (event.request.method === "GET") {
|
||||
event.respondWith(handleRequest(event.request));
|
||||
}
|
||||
});
|
||||
|
||||
function isCacheableThumbnail(url) {
|
||||
|
|
Loading…
Reference in a new issue