Skip to content

Commit

Permalink
Update WidgetsBinding.instance to remove "Warning: Operand of null-aw…
Browse files Browse the repository at this point in the history
…are operation '?.' has type 'WidgetsBinding' which excludes null." warn for flutter 3.0
  • Loading branch information
jstorch72 committed Jun 29, 2022
1 parent 99576bd commit e022d5f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/another_xlider.dart
Original file line number Diff line number Diff line change
Expand Up @@ -438,7 +438,7 @@ class FlutterSliderState extends State<FlutterSlider>
parent: _rightTooltipAnimationController,
curve: Curves.fastOutSlowIn));

WidgetsBinding.instance?.addPostFrameCallback((_) {
WidgetsBinding.instance.addPostFrameCallback((_) {
if (!mounted) {
return;
}
Expand Down

0 comments on commit e022d5f

Please sign in to comment.