We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 7053868 + 7b12504 commit 50cf8bdCopy full SHA for 50cf8bd
lib/puppet/type/file_line.rb
@@ -93,8 +93,8 @@
93
newparam(:path) do
94
desc 'The file Puppet will ensure contains the line specified by the line parameter.'
95
validate do |value|
96
- unless (Puppet.features.posix? and value =~ /^\//) or (Puppet.features.microsoft_windows? and (value =~ /^.:\// or value =~ /^\/\/[^\/]+\/[^\/]+/))
97
- raise(Puppet::Error, "File paths must be fully qualified, not '#{value}'")
+ unless Puppet::Util.absolute_path?(value)
+ raise Puppet::Error, "File paths must be fully qualified, not '#{value}'"
98
end
99
100
0 commit comments