about summary refs log tree commit diff
path: root/src/components/Prompt.tsx
diff options
context:
space:
mode:
authorHailey <me@haileyok.com>2024-04-05 12:52:53 -0700
committerGitHub <noreply@github.com>2024-04-05 12:52:53 -0700
commitcd29dba761dde1e5050675cbc3002b317c5648b4 (patch)
treee8b8e0c7a1c72209526053d19199da9581f46990 /src/components/Prompt.tsx
parentc80dcc565ea64d07d47ebf3e0db617e2c48d2556 (diff)
downloadvoidsky-cd29dba761dde1e5050675cbc3002b317c5648b4.tar.zst
fix dialog back button for android (#3428)
* fix types

* remove unused async

* add try/catch
Diffstat (limited to 'src/components/Prompt.tsx')
-rw-r--r--src/components/Prompt.tsx3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/components/Prompt.tsx b/src/components/Prompt.tsx
index 3344b051b..c92fe2652 100644
--- a/src/components/Prompt.tsx
+++ b/src/components/Prompt.tsx
@@ -135,8 +135,7 @@ export function Action({
   const {gtMobile} = useBreakpoints()
   const {close} = Dialog.useDialogContext()
   const handleOnPress = React.useCallback(() => {
-    close()
-    onPress()
+    close(onPress)
   }, [close, onPress])
 
   return (