diff options
Diffstat (limited to 'lib/puppet/indirector/yaml.rb')
| -rw-r--r-- | lib/puppet/indirector/yaml.rb | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/lib/puppet/indirector/yaml.rb b/lib/puppet/indirector/yaml.rb index 16816d941..4dd29159e 100644 --- a/lib/puppet/indirector/yaml.rb +++ b/lib/puppet/indirector/yaml.rb @@ -2,11 +2,6 @@ require 'puppet/indirector/terminus' # The base class for YAML indirection termini. class Puppet::Indirector::Yaml < Puppet::Indirector::Terminus - def initialize - # Make sure our base directory exists. - Puppet.settings.use(:yaml) - end - # Read a given name's file in and convert it from YAML. def find(name) raise ArgumentError.new("You must specify the name of the object to retrieve") unless name @@ -40,6 +35,11 @@ class Puppet::Indirector::Yaml < Puppet::Indirector::Terminus end end + def version(name) + return nil unless FileTest.exist?(path(name)) + return File.stat(path(name)).mtime + end + private def from_yaml(text) |
