Skip to content

[image_picker][IOS] throws error while canceling from pickMultipleMedia  #133111

@jaypathak9460

Description

@jaypathak9460

Is there an existing issue for this?

Steps to reproduce

  1. install the package on IOS platform
  2. use [ List<XFile>? pickedFileList = await ImagePicker().pickMultipleMedia( requestFullMetadata: true, imageQuality: 100, maxHeight: 100, maxWidth: 100, );].
  3. when picker shows just tap cancel on top left side

Expected results

throw an error PlatformException(null-error, Host platform returned null value for non-null return value., null, null)

Actual results

it should return null or list length of 0 instead of throwing error

Code sample

Code sample

Screenshots or Video

Screenshots / Video demonstration

[Upload media here]

Logs

Logs
[Paste your logs here]

Flutter Doctor output

Doctor output
jaypathak@News-Mac OctaBeesLite % flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel stable, 3.10.6, on macOS 13.2.1 22D68 darwin-x64, locale en-IN)
[!] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    ✗ Android license status unknown.
      Run `flutter doctor --android-licenses` to accept the SDK licenses.
      See https://flutter.dev/docs/get-started/install/macos#android-setup for more details.
[✓] Xcode - develop for iOS and macOS (Xcode 14.3.1)
[✓] Chrome - develop for the web
[!] Android Studio (version 2022.3)
    ✗ Unable to find bundled Java version.
[✓] VS Code (version 1.81.1)
[✓] Connected device (3 available)
[✓] HTTP Host Availability

! Doctor found issues in 2 categories.

Metadata

Metadata

Labels

P1High-priority issues at the top of the work listfound in release: 3.13Found to occur in 3.13found in release: 3.14Found to occur in 3.14fyi-ecosystemFor the attention of Ecosystem teamhas reproducible stepsThe issue has been confirmed reproducible and is ready to work onp: image_pickerThe Image Picker plugin.packageflutter/packages repository. See also p: labels.r: fixedIssue is closed as already fixed in a newer versionteam-iosOwned by iOS platform team

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions