fix: downloading backups in mobile webview (#1703)
This commit is contained in:
@@ -0,0 +1,10 @@
|
||||
import { WebApplication } from '@/Application/Application'
|
||||
import { getBase64FromBlob } from '@/Utils'
|
||||
|
||||
export const shareBlobOnMobile = async (application: WebApplication, blob: Blob, filename: string) => {
|
||||
if (!application.isNativeMobileWeb()) {
|
||||
throw new Error('Share function being used outside mobile webview')
|
||||
}
|
||||
const base64 = await getBase64FromBlob(blob)
|
||||
application.mobileDevice.shareBase64AsFile(base64, filename)
|
||||
}
|
||||
Reference in New Issue
Block a user