diff options
author | Kevin Deisz <kevin.deisz@gmail.com> | 2019-01-21 10:28:39 -0500 |
---|---|---|
committer | Kevin Deisz <kevin.deisz@gmail.com> | 2019-01-21 10:28:39 -0500 |
commit | 65cec345b487a784c9dae4155f74e70befc0bddb (patch) | |
tree | 9e1e3f5dda93fa5e91b180df61d1dbbb221f8fd5 /activerecord/lib/arel | |
parent | feb97dfabd027a73a41ca8bd2ab7c3196ab76d3d (diff) | |
download | rails-65cec345b487a784c9dae4155f74e70befc0bddb.tar.gz rails-65cec345b487a784c9dae4155f74e70befc0bddb.tar.bz2 rails-65cec345b487a784c9dae4155f74e70befc0bddb.zip |
Alias case nodes
When `Arel` was merged into `ActiveRecord` we lost the ability to alias case nodes. This adds it back.
Diffstat (limited to 'activerecord/lib/arel')
-rw-r--r-- | activerecord/lib/arel/nodes/case.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/activerecord/lib/arel/nodes/case.rb b/activerecord/lib/arel/nodes/case.rb index 654a54825e..b8f83128c8 100644 --- a/activerecord/lib/arel/nodes/case.rb +++ b/activerecord/lib/arel/nodes/case.rb @@ -3,6 +3,8 @@ module Arel # :nodoc: all module Nodes class Case < Arel::Nodes::Node + include Arel::AliasPredication + attr_accessor :case, :conditions, :default def initialize(expression = nil, default = nil) |