Update SaveFileButton.tsx

This commit is contained in:
Marcos Rodriguez Velez 2024-04-09 20:31:56 -04:00
parent ecbd200d51
commit 2e45913bc1
No known key found for this signature in database
GPG Key ID: 6030B2F48CCE86D7

View File

@ -38,7 +38,7 @@ const SaveFileButton: React.FC<SaveFileButtonProps> = ({
const action = actions.find(a => a.id === actionId);
if (action?.id === 'save') {
await fs.writeFileAndExport(fileName, fileContent, false, Platform.OS !== 'android').finally(() => {
await fs.writeFileAndExport(fileName, fileContent, Platform.OS !== 'android').finally(() => {
afterOnPress?.(); // Safely call afterOnPress if it exists
});
} else if (action?.id === 'share') {