aboutsummaryrefslogtreecommitdiff
path: root/src/screens/onboarding/Verification.tsx
diff options
context:
space:
mode:
authorIvan Chen <ivan@tagg.id>2021-01-11 16:11:11 -0500
committerIvan Chen <ivan@tagg.id>2021-01-15 14:19:50 -0500
commit080e76350c2570eeb096fad40fe95f1b766b4539 (patch)
treebcb9f73f2c192f8c34f2064a5c3fd003756c2823 /src/screens/onboarding/Verification.tsx
parent1dccfb1d3e9470d81de8d1ec0a0dbb3803372f7d (diff)
created strings.ts and linting
Diffstat (limited to 'src/screens/onboarding/Verification.tsx')
-rw-r--r--src/screens/onboarding/Verification.tsx10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/screens/onboarding/Verification.tsx b/src/screens/onboarding/Verification.tsx
index c808f30b..0fbe0d91 100644
--- a/src/screens/onboarding/Verification.tsx
+++ b/src/screens/onboarding/Verification.tsx
@@ -49,6 +49,10 @@ interface VerificationProps {
}
import {codeRegex} from '../../constants';
+import {
+ ERROR_INVALID_VERIFICATION_CODE_FORMAT,
+ ERROR_SOMETHING_WENT_WRONG,
+} from '../../constants/strings';
const Verification: React.FC<VerificationProps> = ({route, navigation}) => {
const [value, setValue] = React.useState('');
@@ -93,10 +97,10 @@ const Verification: React.FC<VerificationProps> = ({route, navigation}) => {
}
} catch (error) {
console.log(error);
- Alert.alert('Something went wrong');
+ Alert.alert(ERROR_SOMETHING_WENT_WRONG);
}
} else {
- Alert.alert('Please enter a valid 6 digit code');
+ Alert.alert(ERROR_INVALID_VERIFICATION_CODE_FORMAT);
}
};
@@ -115,7 +119,7 @@ const Verification: React.FC<VerificationProps> = ({route, navigation}) => {
}
} catch (error) {
console.log(error);
- Alert.alert('Something went wrong');
+ Alert.alert(ERROR_SOMETHING_WENT_WRONG);
}
};