diff options
author | David Schmitt <david.schmitt@puppet.com> | 2016-10-04 13:48:30 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-04 13:48:30 +0100 |
commit | 440f98b45a79528c36c3286de70f5e8a2fe4466a (patch) | |
tree | 3222c9b0969de0df0d28b8e423f16440243e11cc /lib/puppet/parser/functions/validate_string.rb | |
parent | 7228160175a17fb3d7f5b464553ef6c7791cf140 (diff) | |
parent | cce67b42bb6d09d4e9773b64e28c07d8a93ed088 (diff) |
Merge pull request #662 from domcleal/validate-string-undef
Permit undef passed as `nil` to validate_string
Diffstat (limited to 'lib/puppet/parser/functions/validate_string.rb')
-rw-r--r-- | lib/puppet/parser/functions/validate_string.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/puppet/parser/functions/validate_string.rb b/lib/puppet/parser/functions/validate_string.rb index e92a2fc..0057fc1 100644 --- a/lib/puppet/parser/functions/validate_string.rb +++ b/lib/puppet/parser/functions/validate_string.rb @@ -30,7 +30,7 @@ module Puppet::Parser::Functions end args.each do |arg| - unless arg.is_a?(String) + unless arg.is_a?(String) || arg.nil? raise Puppet::ParseError, ("#{arg.inspect} is not a string. It looks to be a #{arg.class}") end end |