-
Notifications
You must be signed in to change notification settings - Fork 1
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
Add peekError and peekSuccess methods #3
Add peekError and peekSuccess methods #3
Conversation
Those methods can be used to consume success or error values and proceed with the same result. Currently, to do the same logic as onSuccess I have to use flatMap method that returns Result with success value that will be discarded.
9811533
to
32afb11
Compare
Thank you very much for the contribution! I've added a comment about the naming. I think
Thanks!
I think what you've done is the intended process. Can you maybe share what you'd like to see? Something like |
Updated the PR. I think you can add pull request template for your repository. I would be nice if you also add information about Java used for building - I checked the manifest file from distribution jar and found that it was build with 21. And I would be great to have some GitHub actions that runs all checks - I can help with that, just tell me what checks from maven has to be run. |
And may I ask why you are not following Semantic Versioning? |
Ok, I'll try to do it.
I may add this to the README and to the maven-description to be more discoverable.
I think we should run
What do you mean by this? There is only one version, how can I not follow semantic versioning? I think the answer to most of your questions is that I do not have much time for maintenance and such a small library, like this one shouldn't require a lot of maintenance. I would gladly accept any contributions though. |
Thanks for merging.
Semantic versioning assumes that library version is build using at least this: When you will release next version? Can you do it today/tomorrow? I would appreciate it. GitHub action I will add at the evening or tomorrow. |
Will do. Probably tomorrow morning. |
I've release your changes. You can use the new |
Thanks for the library! It is helpful but I found that it lacks two methods that can improve the fluency of its usage.
peekError
andpeekSuccess
methods can be used to consumesuccess
orerror
values and proceed with the same result.Currently, to do the same logic as
peekSuccess
I have to useflatMap
method that returns Result withsuccess
value that will be discarded.I also corrected some spell check issues found by IntelliJ.
I didn't found how information about how to contribute, so I just run tests and checkstyle.
I would be great if you could add something, and add maven goal for automatic formatting.