Skip to content

Issues with 'null' values (project: flutter_rest_api) #2

Description

@tonooga

Excellent example and tutorial! Thanks for sharing it. However, I'm having error messages related to non-null values in the 'note_for_listing.dart' that does not allow the app to run. Only if I make the parameters 'required' it works. But then, other issues comes in the 'note_modify.dart'.

error: The parameter 'noteTitle' can't have a value of 'null' because of its type, but the implicit default value is 'null'. (missing_default_value_for_parameter at [startup_namer] lib\models\note_for_listing.dart:8)

error: The parameter 'noteID' can't have a value of 'null' because of its type, but the implicit default value is 'null'. (missing_default_value_for_parameter at [startup_namer] lib\views\note_modify.dart:12)

I suspect it has to do with the non-null safety feature in flutter but not sure. Any recommendations?
Thanks for the help!

Programming-Addict-Code-Examples/flutter_rest_api/part 1/notes/

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions