aboutsummaryrefslogtreecommitdiffstats
path: root/lib/arel
diff options
context:
space:
mode:
authorKevin Deisz <kevin.deisz@gmail.com>2017-10-27 10:42:09 -0400
committerKevin Deisz <kevin.deisz@gmail.com>2017-10-27 10:42:09 -0400
commit1aeefa68bc93fddfba1d6549bb870d3829dfe0e2 (patch)
treed18c95d125a2e6ed1b8ef5d8067022c09a7b3609 /lib/arel
parent5cc7e774bb4d2190236cdbf46d66c89507ac6933 (diff)
downloadrails-1aeefa68bc93fddfba1d6549bb870d3829dfe0e2.tar.gz
rails-1aeefa68bc93fddfba1d6549bb870d3829dfe0e2.tar.bz2
rails-1aeefa68bc93fddfba1d6549bb870d3829dfe0e2.zip
Allow count nodes to have math functions
Diffstat (limited to 'lib/arel')
-rw-r--r--lib/arel/nodes/count.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/arel/nodes/count.rb b/lib/arel/nodes/count.rb
index a7c6236a22..4dd9be453f 100644
--- a/lib/arel/nodes/count.rb
+++ b/lib/arel/nodes/count.rb
@@ -2,6 +2,8 @@
module Arel
module Nodes
class Count < Arel::Nodes::Function
+ include Math
+
def initialize expr, distinct = false, aliaz = nil
super(expr, aliaz)
@distinct = distinct