Skip to content

Commit

Permalink
ignore promise rejection when user closes sheet
Browse files Browse the repository at this point in the history
  • Loading branch information
CDFN committed May 14, 2024
1 parent 44ee88c commit 4aa4c00
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/frontend/screens/Observation/Buttons.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -103,7 +103,7 @@ export const ButtonFields = ({
const base64Urls = attachmentBase64Queries
.filter(q => !!q.data)
.map(q => q.data!);
await Share.open({
Share.open({
title: base64Urls.length > 0 ? t(m.shareMediaTitle) : t(m.shareTextTitle),
urls: base64Urls,
message: t(m.shareMessage, {
Expand All @@ -112,7 +112,7 @@ export const ButtonFields = ({
time: Date.now(),
coordinates: `Lon ${observation.lon}, Lat ${observation.lat}`,
}),
});
}).catch(() => {});
}

return (
Expand Down

0 comments on commit 4aa4c00

Please sign in to comment.