-
Notifications
You must be signed in to change notification settings - Fork 1.9k
Labels
area-essentials-filepickeri/regressionThis issue described a confirmed regression on a currently supported versionThis issue described a confirmed regression on a currently supported versionpartner/syncfusionIssues / PR's with Syncfusion collaborationIssues / PR's with Syncfusion collaborationplatform/androidplatform/iosregressed-in-10-preview3s/triagedIssue has been reviewedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering TriageVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't workingSomething isn't working
Milestone
Description
Description
FilePicker.PickMultipleAsync() can return null.
The method declaration is Task<IEnumerable<FileResult?>> PickMultipleAsync(PickOptions? options = null);, but it should be Task<IEnumerable<FileResult>?> PickMultipleAsync(PickOptions? options = null);
The IEnumerable should be nullable, not the FileResult.
See issue #27710
Steps to Reproduce
var fileResults = await filePicker.PickMultipleAsync(PickOptions.Default);
// Warning: Expression is always true according to nullable reference types' annotations
if (fileResults is not null)
{
foreach (var fileResult in fileResults)
{
// Dereference of a possibly null reference
Console.WriteLine(fileResult.FileName);
}
}Link to public reproduction project repository
No response
Version with bug
10.0.20
Is this a regression from previous behavior?
No, this is something new
Last version that worked well
No response
Affected platforms
iOS, Android, I was not able test on other platforms
Affected platform versions
No response
Did you find any workaround?
No response
Relevant log output
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
area-essentials-filepickeri/regressionThis issue described a confirmed regression on a currently supported versionThis issue described a confirmed regression on a currently supported versionpartner/syncfusionIssues / PR's with Syncfusion collaborationIssues / PR's with Syncfusion collaborationplatform/androidplatform/iosregressed-in-10-preview3s/triagedIssue has been reviewedIssue has been revieweds/verifiedVerified / Reproducible Issue ready for Engineering TriageVerified / Reproducible Issue ready for Engineering Triaget/bugSomething isn't workingSomething isn't working