async function checkPermission() {
        if (Platform.OS !== 'web') {
            const { status } = await ImagePicker.requestMediaLibraryPermissionsAsync();
            if (status !== 'granted') {
                alert('Sorry, we need camera roll permissions to make this work!');
                return false;
            } else {
                return true;
            }
        }
    }
//A function that checks if permission to access images has been granted.
A function that checks if permission to access images has been granted.
A function that checks if permission to access images has been granted .
async function checkPermission() {
        if (Platform.OS !== 'web') {
            const { status } = await ImagePicker.requestMediaLibraryPermissionsAsync();
            if (status !== 'granted') {
                alert('Sorry, we need camera roll permissions to make this work!');
                return false;
            } else {
                return true;
            }
        }
    }
async function checkPermission ( ) { if ( Platform . OS !== 'web' ) { const { status } = await ImagePicker . requestMediaLibraryPermissionsAsync ( ) ; if ( status !== 'granted' ) { alert ( 'Sorry, we need camera roll permissions to make this work!' ) ; return false ; } else { return true ; } } }
A function that checks if permission to access images has been granted.
A function that checks if permission to access images has been granted .