Move make live methods into make live form model#1063
Merged
DavidBiddle merged 1 commit intomainfrom Apr 2, 2024
Merged
Conversation
chao-xian
approved these changes
Apr 2, 2024
Contributor
chao-xian
left a comment
There was a problem hiding this comment.
Thank you for making this change! Can we also reword the commit message with a "why" that the controller shouldn't have such private methods that are really belonging in the domain of the model itself pls?
Moves the user_wants_to_make_form_live and make_form_live methods out of the make_live_controller and the unarchive_controller and into the make_live_form model. This means that the controller no longer holds logic in private methods that ought to be in the model's domain, reduces duplication between the two controllers, and makes it easier to unit test these methods.
a780054 to
4886dc5
Compare
|
Contributor
Author
|
Thanks @chao-xian, have added that context to the commit message 👍 |
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.




What problem does this pull request solve?
Trello card: https://trello.com/c/li50etsD/1432-implement-form-unarchiving (tidying up)
This is a refactor which moves the duplicated
user_wants_to_make_form_liveandmake_form_livemethods out of themake_live_controllerand theunarchive_controller, and into themake_live_formmodel.Things to consider when reviewing