Remove EnumWithNil helper
What does this MR do and why?
Commit that introduced the change: 0665a8f7
Enums are working correctly with nil values in Rails 6.1, we can remove the helper.
- Rails 5: https://github.com/rails/rails/blob/v5.2.8.1/activerecord/lib/active_record/enum.rb#L151
- Rails 6.1: https://github.com/rails/rails/blob/f0c5e60aed8bdce96c385cad05b1e34d7d757038/activerecord/lib/active_record/enum.rb#L232
public_send(:"#{name}_for_database") == value
is used instead and "#{name}_for_database"
returns nil
when the database value is nil
.
Even more context, Rails 7 changed the method signature of enum
method: !90907 (e621267c)
Merge request reports
Activity
changed milestone to %15.10
assigned to @igor.drozdov
added devopscreate sectiondev labels
Reviewer roulette
Changes that require review have been detected!
Please refer to the table below for assigning reviewers and maintainers suggested by Danger in the specified category:
Category Reviewer Maintainer backend Ravi Kumar (
@rkumar555
) (UTC+1, same timezone as@igor.drozdov
)Peter Leitzen (
@splattael
) (UTC+1, same timezone as@igor.drozdov
)To spread load more evenly across eligible reviewers, Danger has picked a candidate for each review slot, based on their timezone. Feel free to override these selections if you think someone else would be better-suited or use the GitLab Review Workload Dashboard to find other available reviewers.
To read more on how to use the reviewer roulette, please take a look at the Engineering workflow and code review guidelines. Please consider assigning a reviewer or maintainer who is a domain expert in the area of the merge request.
Once you've decided who will review this merge request, assign them as a reviewer! Danger does not automatically notify them for you.
If needed, you can retry the
danger-review
job that generated this comment.Generated by
DangerEdited by Ghost User- Resolved by Peter Leitzen
@jprovaznik could you please review this merge request whenever you're not busy? It's not urgent
requested review from @jprovaznik
@jprovaznik
, thanks for approving this merge request.This is the first time the merge request is approved. To ensure full test coverage, a new pipeline will be started shortly.
For more info, please refer to the following links:
added pipeline:mr-approved label
requested review from @splattael and removed review request for @jprovaznik
added rails label
- Resolved by Peter Leitzen
mentioned in commit bfe5e5f0
added workflowstaging-canary label
added workflowcanary label and removed workflowstaging-canary label