Light refactor to v2 receiver for readability#1585
Open
xstoicunicornx wants to merge 1 commit into
Open
Conversation
Restructure match arms in the v2 receiver typestates to return directly from each branch instead of binding an intermediate value and returning after the match. Also rename a shadowed `inner` binding to `payjoin_psbt` for clarity.
Collaborator
Coverage Report for CI Build 26543710624Coverage increased (+0.004%) to 85.144%Details
Uncovered Changes
Coverage RegressionsNo coverage regressions found. Coverage Stats
💛 - Coveralls |
2 tasks
arminsabouri
approved these changes
May 27, 2026
Contributor
arminsabouri
left a comment
There was a problem hiding this comment.
cACK 6da7ae5
Meta nit: In the future please consider splitting the renaming and test changes (if they are unrelated to a refactor) into seperate commits.
Thanks!
Collaborator
Author
|
Meta nit noted! Thank you for the feedback. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This is a light refactor to mainly restructure match arms in the v2 receiver typestates to return directly from each branch instead of binding an intermediate value and returning after the match. Also renames a shadowed
innerbinding topayjoin_psbtfor clarity and adds consistency to.save().expect()pattern in a test.This refactor was written in preparation of implementing PR 1446. Improving the readability of these match arms will make it easier to review the interface changes introduced in PR 1446.
Pull Request Checklist
Please confirm the following before requesting review:
AI
in the body of this PR.