-
Notifications
You must be signed in to change notification settings - Fork 39
Open
Description
Dear All,
I've noticed an issue when I call setState inside _onSaved function.
Basically, I need to set the selected values in my state.
onSaved: (value) {
setState(() => this.selectedData = value);
}
This line causes the error:
The following NoSuchMethodError was thrown building MultiSelect(dirty, dependencies: [_FormScope], state: FormFieldState<dynamic>#140cb): The method '[]' was called on null. Receiver: null Tried calling: []("display")
It's well known that forms are reloaded on setState function (see here), but how to solve this issue for the library?
Sincerely,
Francesco
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels