Skip to content

Commit 32dbac0

Browse files
committed
Merge pull request #169 from hdeheer/patch-1
Fix validate_slength, arg.length should be args[0].length
2 parents 0a02295 + 77625e6 commit 32dbac0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/puppet/parser/functions/validate_slength.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ module Puppet::Parser::Functions
4949

5050
case args[0]
5151
when String
52-
raise Puppet::ParseError, ("validate_slength(): #{args[0].inspect} is #{args[0].length} characters. It should have been between #{min_length} and #{max_length} characters") unless args[0].length <= max_length and min_length <= arg.length
52+
raise Puppet::ParseError, ("validate_slength(): #{args[0].inspect} is #{args[0].length} characters. It should have been between #{min_length} and #{max_length} characters") unless args[0].length <= max_length and min_length <= args[0].length
5353
when Array
5454
args[0].each do |arg|
5555
if arg.is_a?(String)

0 commit comments

Comments
 (0)