summaryrefslogtreecommitdiff
path: root/lib/puppet/parser
diff options
context:
space:
mode:
authorstephen <stephen@puppetlabs.com>2013-01-03 13:53:03 +0000
committerJeff McCune <jeff@puppetlabs.com>2013-01-03 13:37:55 -0800
commit190b9438c58eab2322bdf216be1aaae109d14072 (patch)
treeabbec3c0a8732b520d79c5d852d395312937f2c9 /lib/puppet/parser
parente1f2a932883c71038d78938efd46cdb30c01da6d (diff)
downloadpuppet-stdlib-190b9438c58eab2322bdf216be1aaae109d14072.tar.gz
puppet-stdlib-190b9438c58eab2322bdf216be1aaae109d14072.tar.bz2
Add test/validation for is_numeric if created from an arithmetical operation
Diffstat (limited to 'lib/puppet/parser')
-rw-r--r--lib/puppet/parser/functions/is_numeric.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/puppet/parser/functions/is_numeric.rb b/lib/puppet/parser/functions/is_numeric.rb
index ce13ece..abf0321 100644
--- a/lib/puppet/parser/functions/is_numeric.rb
+++ b/lib/puppet/parser/functions/is_numeric.rb
@@ -15,7 +15,7 @@ Returns true if the variable passed to this function is a number.
value = arguments[0]
- if value == value.to_f.to_s or value == value.to_i.to_s then
+ if value == value.to_f.to_s or value == value.to_i.to_s or value.is_a? Numeric then
return true
else
return false