Skip to content

Commit

Permalink
Update useDeleteFile.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
tristandostaler authored Sep 9, 2024
1 parent d2e120c commit 8f1e484
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/hooks/AppWriteAPI/useDeleteFile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ const useDeleteFile = (isLoginProcess: boolean) => {
}

const deleteFile = (fileName: string) => {
return storage.deleteFile(storageBucketId, fileName).catch(reLogin);;
return storage.deleteFile(storageBucketId, fileName).catch((reason) => reLogin(reason));;
}
return deleteFile;
};

export default useDeleteFile;
export default useDeleteFile;

0 comments on commit 8f1e484

Please sign in to comment.