summaryrefslogtreecommitdiffstats
path: root/lib/puppet/parser
diff options
context:
space:
mode:
Diffstat (limited to 'lib/puppet/parser')
-rw-r--r--lib/puppet/parser/templatewrapper.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/lib/puppet/parser/templatewrapper.rb b/lib/puppet/parser/templatewrapper.rb
index 62b45852b..3b8cc3a3a 100644
--- a/lib/puppet/parser/templatewrapper.rb
+++ b/lib/puppet/parser/templatewrapper.rb
@@ -7,11 +7,7 @@ class Puppet::Parser::TemplateWrapper
def initialize(scope, file)
@scope = scope
- if file =~ /^#{File::SEPARATOR}/
- @file = file
- else
- @file = File.join(Puppet[:templatedir], file)
- end
+ @file = Puppet::Module::find_template(file)
unless FileTest.exists?(@file)
raise Puppet::ParseError,