chore: fix build errors

This commit is contained in:
Aman Harwara
2023-08-24 17:04:43 +05:30
parent 999bbde1b0
commit e41f239cc5
2 changed files with 3 additions and 3 deletions

View File

@@ -355,7 +355,7 @@ export class WebApplication extends SNApplication implements WebApplicationInter
const filesController = this.filesController
const blob = getBlobFromBase64(file.data, file.mimeType)
const mappedFile = new File([blob], file.name, { type: file.mimeType })
filesController.uploadNewFile(mappedFile, true).catch(console.error)
filesController.uploadNewFile(mappedFile).catch(console.error)
}
async handleReceivedTextEvent({ text, title }: { text: string; title?: string | undefined }) {
@@ -397,7 +397,7 @@ export class WebApplication extends SNApplication implements WebApplicationInter
const file = new File([imgBlob], finalPath, {
type: imgBlob.type,
})
this.filesController.uploadNewFile(file, true).catch(console.error)
this.filesController.uploadNewFile(file).catch(console.error)
} catch (error) {
console.error(error)
} finally {

View File

@@ -44,7 +44,7 @@ const RemoteImageComponent = ({ className, src, alt, node, format, nodeKey }: Pr
const { filesController, linkingController } = application
const uploadedFile = await filesController.uploadNewFile(file, false)
const uploadedFile = await filesController.uploadNewFile(file, { showToast: false })
if (!uploadedFile) {
return