Skip to content

Commit 9336f5a

Browse files
itsalongstoryscarroll32Copilot
authored
Fix ransack_alias issue, close #1239 (#1512)
* Fix `ransack_alias` issue, close #1239 * Update lib/ransack/nodes/grouping.rb Co-authored-by: Copilot <[email protected]> --------- Co-authored-by: Sean <[email protected]> Co-authored-by: Copilot <[email protected]>
1 parent 1109829 commit 9336f5a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/ransack/nodes/grouping.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ def [](key)
5353
end
5454

5555
def []=(key, value)
56-
conditions.reject! { |c| c.key == key.to_s }
56+
conditions.reject! { |c| c.key == key.to_s && c&.value == value&.value }
5757
self.conditions << value
5858
end
5959

0 commit comments

Comments
 (0)