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

Rename method to avoid misleading readers #2489

Merged
merged 1 commit into from
Jan 8, 2025

Conversation

mtaylorgds
Copy link
Contributor

The destroyable_edition? method had a misleading name, as it isn't a
querying method that returns a boolean value—it checks whether an
edition is destroyable and, if it isn't, shows a flash message and
redirects to the edition's show page.

There's already a similar method, require_assignee_editable, for
checking whether an edition can have its assignee updated, so rename
the method to be consistent with that one.

⚠️ This repo is Continuously Deployed: make sure you follow the guidance ⚠️

The `destroyable_edition?` method had a misleading name, as it isn't a
 querying method that returns a boolean value—it checks whether an
 edition is destroyable and, if it isn't, shows a flash message and
 redirects to the edition's show page.

There's already a similar method, `require_assignee_editable`, for
 checking whether an edition can have its assignee updated, so rename
 the method to be consistent with that one.
@mtaylorgds mtaylorgds merged commit 2907d40 into main Jan 8, 2025
13 checks passed
@mtaylorgds mtaylorgds deleted the rename-method-to-avoid-confusion branch January 8, 2025 11:56
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