You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I get a null reference exception when the SearchFunc is called if I bind the MudAutocomplete to a nullable field of type string?. This was not expected as the signature of SearchFunc is Func<string, Task<IEnumerable<string?>>>, i.e. the incoming string is not null.
Expected behavior
I expect the signature to be Func<string?, Task<IEnumerable<string?>>> when binding to a field of type string?.
Hello @Apollo3zehn. At the moment, MudBlazor doesn't support nullable annotations. However, work is currently underway to address this issue. You can track the progress of this work in the following ticket: #6535.
Bug type
Component
Component name
MudAutocomplete<string?>
What happened?
I get a null reference exception when the
SearchFunc
is called if I bind theMudAutocomplete
to a nullable field of typestring?
. This was not expected as the signature ofSearchFunc
isFunc<string, Task<IEnumerable<string?>>>
, i.e. the incoming string is not null.Expected behavior
I expect the signature to be
Func<string?, Task<IEnumerable<string?>>>
when binding to a field of typestring?
.Reproduction link
https://try.mudblazor.com/snippet/GawRYIYNSFRkgTAR
Reproduction steps
Click into the AutoComplete field. The result will be displayed as
Is search string null after click? True
.Relevant log output
No response
Version (bug)
6.2.0
Version (working)
No response
What browsers are you seeing the problem on?
Microsoft Edge
On what operating system are you experiencing the issue?
Windows
Pull Request
Code of Conduct
The text was updated successfully, but these errors were encountered: