mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-17 23:18:27 +02:00
Fix in image picker filter to prevent live photos and videos to be picked
This commit is contained in:
@@ -126,7 +126,7 @@ final class SingleImagePickerPresenter: NSObject {
|
||||
|
||||
if BWIBuildSettings.shared.useNewPhotosPickerAPI {
|
||||
var configuration = PHPickerConfiguration(photoLibrary: PHPhotoLibrary.shared())
|
||||
configuration.filter = PHPickerFilter.any(of: [.images, .videos])
|
||||
configuration.filter = .images
|
||||
configuration.preferredAssetRepresentationMode = .compatible
|
||||
configuration.selection = .default
|
||||
configuration.selectionLimit = 1
|
||||
@@ -207,6 +207,8 @@ extension SingleImagePickerPresenter: PHPickerViewControllerDelegate {
|
||||
}
|
||||
}
|
||||
}
|
||||
} else if itemProvider.canLoadObject(ofClass: PHLivePhoto.self) {
|
||||
MXLog.error("itemProvider.canLoadObject(ofClass: PHLivePhoto.self)")
|
||||
} else {
|
||||
self.delegate?.singleImagePickerPresenterDidCancel(self)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user