Skip to content
This repository has been archived by the owner on May 15, 2024. It is now read-only.

Commit

Permalink
Update MediaPicker.android.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
mattleibow authored Jan 24, 2023
1 parent 232cc1f commit 19e3f5c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Xamarin.Essentials/MediaPicker/MediaPicker.android.cs
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ static async Task<FileResult> PlatformCaptureAsync(MediaPickerOptions options, b
{
await Permissions.EnsureGrantedAsync<Permissions.Camera>();
// StorageWrite no longer exists starting from Android API 33
if (!OperatingSystem.IsAndroidVersionAtLeast(33))
if (!Platform.HasApiLevel(33))
await Permissions.EnsureGrantedAsync<Permissions.StorageWrite>();

var capturePhotoIntent = new Intent(photo ? MediaStore.ActionImageCapture : MediaStore.ActionVideoCapture);
Expand Down

0 comments on commit 19e3f5c

Please sign in to comment.