From c3cc16274d2a2cc0b394bb7ec7fbb8b45491abcc Mon Sep 17 00:00:00 2001 From: luke Date: Mon, 9 Oct 2006 16:44:38 +0000 Subject: Fixing #309 -- files now correctly replace any number of slashes with a single slash. Also, trailing slashes are removed, since that is how Puppet expects to find files internally. git-svn-id: https://reductivelabs.com/svn/puppet/trunk@1749 980ebf18-57e1-0310-9a29-db15c13687c0 --- lib/puppet/type/pfile.rb | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib') diff --git a/lib/puppet/type/pfile.rb b/lib/puppet/type/pfile.rb index d89fe17e3..3a07acac7 100644 --- a/lib/puppet/type/pfile.rb +++ b/lib/puppet/type/pfile.rb @@ -421,6 +421,10 @@ module Puppet @clients = {} super + + # Get rid of any duplicate slashes, and remove any trailing slashes. + @title = @title.gsub(/\/+/, "/").sub(/\/$/, "") + # Clean out as many references to any file paths as possible. # This was the source of many, many bugs. @arghash = tmphash -- cgit