aboutsummaryrefslogtreecommitdiff
path: root/src/utils/camera.ts
diff options
context:
space:
mode:
authorIvan Chen <ivan@tagg.id>2021-06-30 15:18:57 -0400
committerIvan Chen <ivan@tagg.id>2021-06-30 15:18:57 -0400
commitc548f8df62c3775058ffa18e201ca230a641e6c1 (patch)
tree19e1f72cbc6f46f9ad98d2800e6f6d36a8c4dd43 /src/utils/camera.ts
parentd22e3508a4122575c064bbcb2df94a6e07bce7eb (diff)
Cleanup code
Diffstat (limited to 'src/utils/camera.ts')
-rw-r--r--src/utils/camera.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/utils/camera.ts b/src/utils/camera.ts
index 1ee5dbf4..877c8c2f 100644
--- a/src/utils/camera.ts
+++ b/src/utils/camera.ts
@@ -6,7 +6,7 @@ import ImagePicker, {Image, Video} from 'react-native-image-crop-picker';
import {ERROR_UPLOAD} from '../constants/strings';
/*
- * Captures a photo and pauses to shoe the preview of the picture taken
+ * Captures a photo and pauses to show the preview of the picture taken
*/
export const takePicture = (
cameraRef: RefObject<RNCamera>,
@@ -24,7 +24,7 @@ export const takePicture = (
}
};
-export const downloadImage = (capturedImageURI: string) => {
+export const saveImageToGallery = (capturedImageURI: string) => {
CameraRoll.save(capturedImageURI, {album: 'Recents', type: 'photo'})
.then((_res) => Alert.alert('Saved to device!'))
.catch((_err) => Alert.alert('Failed to save to device!'));