aboutsummaryrefslogtreecommitdiffstats
path: root/helpers.jsx
blob: cf95ac2d573046a12a693847c583452c4f3c158a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
import { Alert } from 'react-native';

export const confirmLogout = ({ logout, email }) => {
  Alert.alert(
    'Are you sure?',
    `Do you want to log out user ${email}?`,
    [
      {
        text: 'Logout',
        onPress: logout,
        style: 'destructive',
      },
      {
        text: 'Cancel',
        onPress: () => {},
        style: 'cancel',
      },
    ],
  );
}