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

- Updated library to null-safety #21

Merged
merged 3 commits into from
May 26, 2021

Conversation

AlexBacich
Copy link
Collaborator

  • Fixed tests
  • Fixed example with tests
  • Overall cleanup and small bugfix

- Fixed tests
- Fixed example with tests
- Overall cleanup and small bugfix
@AlexBacich
Copy link
Collaborator Author

@escamoteur , please review and publish.

I've fixed and run all unit \ functional tests in the library and example so that might be good to go without thorough review.

@AlexBacich AlexBacich mentioned this pull request Apr 25, 2021
@escamoteur
Copy link
Owner

could you check if your PR still works with the latest now safe version of RX command 6.0.0-null-safety.3?

@AlexBacich
Copy link
Collaborator Author

Done, all tests passed, updated PR

Copy link
Owner

@escamoteur escamoteur left a comment

Choose a reason for hiding this comment

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

I left some comments.
Thanks a lot for your work!!!!

lib/src/builder_functions.dart Outdated Show resolved Hide resolved
lib/src/builder_functions.dart Outdated Show resolved Hide resolved
lib/src/reactive_base_widget.dart Outdated Show resolved Hide resolved
lib/src/reactive_builder.dart Outdated Show resolved Hide resolved
lib/src/reactive_widget.dart Outdated Show resolved Hide resolved
class RxCommandBuilder<R> extends StatelessWidget {
final Stream<CommandResult<dynamic, R>> commandResults;
final RxBuilder<R>? dataBuilder;
final ErrorBuilder<Exception>? errorBuilder;
Copy link
Owner

Choose a reason for hiding this comment

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

Wouldn't it make sense to pass the full CommandError to the errorBuilder ? On that note I just wonder if not all error handlers/builders should be defined to expect CommandErrors.
I know this would be a major breaking change, but the ability to access the paramData is a huge advantage to display meaningful error messages

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This makes sense, didn't see it before. I think will use it.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Updated. I don't think we should define CommandErrors in all builders as this one is specific to rxCommand.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Please review. all changes.

lib/src/rx_command_builder.dart Outdated Show resolved Hide resolved
lib/src/widget_selector.dart Outdated Show resolved Hide resolved
- Updated rx_command_builder.dart: made it work with CommandError
@AlexBacich
Copy link
Collaborator Author

@escamoteur , ping

@escamoteur escamoteur merged commit f0871b2 into escamoteur:master May 26, 2021
@escamoteur
Copy link
Owner

did you also update the readme?

@AlexBacich
Copy link
Collaborator Author

Good point. I will update with the next update.

@escamoteur
Copy link
Owner

Just fixed the other open issue with #19 and pushed V4.0.1

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.

2 participants