Skip to content

Commit

Permalink
Drop global variable references
Browse files Browse the repository at this point in the history
  • Loading branch information
GeorgeKaraszi committed Nov 16, 2024
1 parent 6e58fad commit a296af9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/active_record_extended/query_methods/unionize.rb
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ def unionize_storage!
union_values: DEFAULT_STORAGE_VALUE,
union_operations: DEFAULT_STORAGE_VALUE,
union_ordering_values: DEFAULT_STORAGE_VALUE,
unionized_name: proc { @table.name }
unionized_name: proc { arel_table.name }
}.each_pair do |method_name, default|
define_method(method_name) do
if send(:"#{method_name}?")
Expand Down Expand Up @@ -144,7 +144,7 @@ def to_nice_union_sql(color = true)

protected

def build_unions(arel = @table)
def build_unions(arel)
return unless union_values?

union_nodes = apply_union_ordering(build_union_nodes!)
Expand Down

0 comments on commit a296af9

Please sign in to comment.