We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hi i'm using this library and when I integret it with my code then it gives this type of error i dont knw why im getting this please help mi.
The argument type 'void Function(bool)' can't be assigned to the parameter type 'void Function(bool?)?'
onSelectChanged: (bool value) { if (dessert.selected != value) { setState(() { dessert.selected = value; }); } },
The text was updated successfully, but these errors were encountered:
@Shubham-Narkhede The problem is the boolean, which get's passed into your function, it may be null.
Reason for that is the following code:
onChanged: (bool? value) { setState(() { widget.rows[index].onSelectChanged!(value); }); },
Look here for reference: data_tables
So you're code must look like the following:
onSelectChanged: (bool? value) { if (dessert.selected != value) { setState(() { dessert.selected = value; }); } },
Sorry, something went wrong.
Could you open a PR?
@rodydavis do you mean to make this one explizit not-nullable? So that the version off @Shubham-Narkhede is valid?
No branches or pull requests
Hi i'm using this library and when I integret it with my code then it gives this type of error i dont knw why im getting this please help mi.
The argument type 'void Function(bool)' can't be assigned to the parameter type 'void Function(bool?)?'
The text was updated successfully, but these errors were encountered: