fix: add pwa=true query param when sharing files (#2004)
This commit is contained in:
parent
fd321720f2
commit
3bf744d2c5
|
@ -115,7 +115,10 @@ self.addEventListener('fetch', event => {
|
|||
const file = formData.get('file')
|
||||
await setWebShareData({ title, text, url, file })
|
||||
await closeKeyValIDBConnection() // don't need to keep the IDB connection open
|
||||
return Response.redirect('/', 303) // 303 recommended by https://web.dev/web-share-target/
|
||||
return Response.redirect(
|
||||
'/?pwa=true', // same as start_url in manifest.json. This can only be invoked from PWAs
|
||||
303 // 303 recommended by https://web.dev/web-share-target/
|
||||
)
|
||||
}
|
||||
|
||||
// always serve webpack-generated resources and
|
||||
|
|
Loading…
Reference in a new issue