Skip to content
New issue

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

[FLUTTER 3] Warning: Operand of null-aware operation '?.' has type 'WidgetsBinding' which excludes null. #91 #309

Open
dJani97 opened this issue May 17, 2022 · 3 comments

Comments

@dJani97
Copy link

dJani97 commented May 17, 2022

Describe the bug

When running the project, a couple of warnings like this are displayed:

../../AppData/Local/Pub/Cache/hosted/pub.dartlang.org/flutter_form_bloc-0.30.1/lib/src/flutter_typeahead.dart:985:22: Warning: Operand of null-aware operation '!' has type 'WidgetsBinding' which excludes null.
 - 'WidgetsBinding' is from 'package:flutter/src/widgets/binding.dart' ('/C:/Apps/flutter/packages/flutter/lib/src/widgets/binding.dart').
      WidgetsBinding.instance!.addPostFrameCallback((duration) {
                     ^

In Flutter 3, WidgetsBinding.instance is no longer nullable, so the ?. operator is not necessary.

To Reproduce
Reproducible by using Flutter 3 and flutter_form_bloc: ^0.30.1.

@vasilich6107
Copy link

@dJani97
This is not the first time when form_bloc has issues with delivery

Today I removed last piece of code and form_bloc as dependancy.

I recommend you pay attaention to reactive_forms

@dJani97
Copy link
Author

dJani97 commented Aug 30, 2022

Please, merge & make at least a pre-release of this.

@vasilich6107
Copy link

#312 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants