diff --git a/native/account/fullscreen-siwe-panel.react.js b/native/account/fullscreen-siwe-panel.react.js
--- a/native/account/fullscreen-siwe-panel.react.js
+++ b/native/account/fullscreen-siwe-panel.react.js
@@ -9,7 +9,7 @@
import SIWEPanel from './siwe-panel.react.js';
type Props = {
- +onClose: () => mixed,
+ +goBackToPrompt: () => mixed,
+closing: boolean,
};
function FullscreenSIWEPanel(props: Props): React.Node {
@@ -24,18 +24,18 @@
[],
);
- const onCloseProp = props.onClose;
+ const { goBackToPrompt } = props;
const siweServerCallParams = React.useMemo(() => {
const onServerCallFailure = () => {
Alert.alert(
'Unknown error',
'Uhh... try again?',
- [{ text: 'OK', onPress: onCloseProp }],
+ [{ text: 'OK', onPress: goBackToPrompt }],
{ cancelable: false },
);
};
return { onFailure: onServerCallFailure };
- }, [onCloseProp]);
+ }, [goBackToPrompt]);
const siweServerCall = useSIWEServerCall(siweServerCallParams);
const successRef = React.useRef(false);
@@ -47,11 +47,11 @@
[siweServerCall],
);
- const onClose = React.useCallback(() => {
+ const ifBeforeSuccessGoBackToPrompt = React.useCallback(() => {
if (!successRef.current) {
- onCloseProp();
+ goBackToPrompt();
}
- }, [onCloseProp]);
+ }, [goBackToPrompt]);
const { closing } = props;
return (
@@ -59,8 +59,8 @@
{activity}
diff --git a/native/account/logged-out-modal.react.js b/native/account/logged-out-modal.react.js
--- a/native/account/logged-out-modal.react.js
+++ b/native/account/logged-out-modal.react.js
@@ -598,7 +598,7 @@
if (this.state.mode === 'siwe') {
siwePanel = (
);