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

fix bugs generated by _steps null in discoverFeatures and _alreadyCompletedSteps methods #42

Open
wants to merge 11 commits into
base: master
Choose a base branch
from

Conversation

frsisalima
Copy link

fix bugs generated by _steps null in discoverFeatures and _alreadyCompletedSteps methods

@ayalma
Copy link
Owner

ayalma commented Oct 8, 2020

Conflicting files
example/.flutter-plugins-dependencies
pls solve this first

@marciocesarcorrea
Copy link

Is this pr stopped?

@noordawod
Copy link
Contributor

Conflicting files
example/.flutter-plugins-dependencies
pls solve this first

This file shouldn't even be in VCS.

@narcodico
Copy link

@ayalma will you merge this PR anytime soon? Your package is unusable without addressing this issue.

@@ -110,7 +110,7 @@ class Bloc {

_steps = steps;
_stepsToIgnore = await _alreadyCompletedSteps;
_steps = _steps.where((s) => !_stepsToIgnore.contains(s)).toList();
_steps = _steps!=null?_steps.where((s) => !_stepsToIgnore.contains(s)).toList():[];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What's your problem with spacing? :)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know what is the problem, the log error is:

lib/src/foundation/bloc.dart
lib/src/rendering/custom_layout.dart
test/feature_discovery_test.dart
Formatting failed: 1
Error: Process completed with exit code 1.

@noordawod
Copy link
Contributor

You should run flutter format on the files.

Copy link
Author

@frsisalima frsisalima left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have run flutter format

_steps = _steps.where((s) => !_stepsToIgnore.contains(s)).toList();
_steps = _steps != null
? _steps.where((s) => !_stepsToIgnore.contains(s)).toList()
: [];
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This could be rewritten nicely like so:

_steps = _steps?.where((s) => !_stepsToIgnore.contains(s)).toList() ?? [];

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same problem :(

? _steps
.where((s) => prefs.getBool('$sharedPrefsPrefix$s') == true)
.toSet()
: {};
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here:

return _steps?.where((s) => prefs.getBool('$sharedPrefsPrefix$s') == true).toSet() ?? {};

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same problem :(

@noordawod
Copy link
Contributor

I have run flutter format

One test is still failing because of formatting, maybe run it again.

@abbasidaniyal
Copy link

Can we please merge this PR? A small linting issue is making this great library unusable.

@marciocesarcorrea
Copy link

Will this PR be waiting?

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.

6 participants