Commit 745509f3 authored by Mickaël Canévet's avatar Mickaël Canévet
Browse files

Merge pull request #79 from oferzi23/master

fix validation for source and content vars
parents be33e7ef 9705585e
......@@ -31,8 +31,10 @@ define postfix::hash (
include ::postfix::params
validate_absolute_path($name)
validate_string($source)
validate_string($content)
# validate_string($source)
# validate_string($content)
if !is_string($source) and !is_array($source) { fail("value for source should be either String type or Array type got ${source}") }
if !is_string($content) and !is_array($content) { fail("value for source should be either String type or Array type got ${content}") }
validate_string($ensure)
validate_re($ensure, ['present', 'absent'],
"\$ensure must be either 'present' or 'absent', got '${ensure}'")
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment