Fix wrong previouos merged conflict

This commit is contained in:
Nicola Benaglia 2025-06-12 22:57:48 +02:00
parent 0249573890
commit a7d476bb1c

View File

@ -2463,7 +2463,6 @@ export const saveFile = async (data, sender, isFromExtension, snackMethods) => {
const filename = data.filename;
const blob = data.blob;
const mimeType = blob.type || data.mimeType;
const resPermission = await getUserPermission(
{
text1: i18n.t('question:download_file', {
@ -2474,17 +2473,6 @@ export const saveFile = async (data, sender, isFromExtension, snackMethods) => {
isFromExtension
);
const { accepted } = resPermission;
if (!accepted) throw new Error('User declined to save file'); // TODO translate
showSaveFilePicker(
{
filename,
mimeType,
blob,
},
snackMethods
);
return true;
if (accepted) {
const mimeType = blob.type || data.mimeType;