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

Use relation.and instead of relation.merge whenever possible. #695

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from

Commits on Feb 24, 2021

  1. Use relation.and instead of relation.merge whenever possible.

    `relation.merge` intends to mimics Hash#merge,
    (i.e. later condition on the same column replaces the previous one)
    
    see rails/rails#39250 & rails/rails#40944
    
    Using relation#merge would cause suprising result when you try to limit
    the resource collection through nesting while the foreign_key also has
    condition in ability rule scope.
    Albert Song committed Feb 24, 2021
    Configuration menu
    Copy the full SHA
    b4b289c View commit details
    Browse the repository at this point in the history