[v4.6] Fix return item initialization in backend#6415
Merged
Conversation
This fixes an issue with the `display_` money methods which require the instance to define a public method for `#currency`. It seems like this has been broken for a while, which meant the currency for `ReturnItem`s would always use the store default configured currency. Co-authored-by: Alistair Norman <alistair@super.gd> (cherry picked from commit 6e9a0c7)
This change ensures that return items built for a new return authorization are correctly associated with it. This will ensure that the display_* methods use the currency from the return authorization, instead of the default store currency. Co-authored-by: Alistair Norman <alistair@super.gd> (cherry picked from commit a570cc0)
5 tasks
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## v4.6 #6415 +/- ##
=======================================
Coverage 89.36% 89.37%
=======================================
Files 963 963
Lines 20213 20213
=======================================
+ Hits 18064 18065 +1
+ Misses 2149 2148 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
mamhoff
approved these changes
Feb 2, 2026
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.
Backport
This will backport the following commits from
maintov4.6:Questions ?
Please refer to the Backport tool documentation