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

Migration to null safety dart 2.0 #50

Merged
merged 1 commit into from
Apr 25, 2021
Merged

Conversation

Kalela
Copy link
Contributor

@Kalela Kalela commented Mar 8, 2021

I migrated all the files to their null safe versions by running dart migrate and removing some of the bugs that came up. Here are the changes that I made:

  1. Some factory constructors had to be converted to static methods. This is because null safety Dart 2.0 allows static methods to return null but not factory methods.
  2. Updated pubspec dependencies to null safe variants.
  3. Made most fields nullable and maintained the null checks that were present before. Especially in factory constructors. I did not want to start changing the logic for where the return values were used.

Closes #49

@Kalela Kalela mentioned this pull request Mar 8, 2021
@niravanu
Copy link

@witochandra Could you accept this pull request. Thanks!

@witochandra witochandra merged commit 3e34246 into witochandra:master Apr 25, 2021
@witochandra
Copy link
Owner

Thanks @Kalela for this PR. 👍

Did few refactoring after this PR, basically bringing back factory methods so it is consistent.

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 this pull request may close these issues.

Null Safety
3 participants