summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorLuke Kanies <luke@madstop.com>2009-02-20 09:45:42 -0600
committerLuke Kanies <luke@madstop.com>2009-02-20 09:45:42 -0600
commit25a3f59be4a514629db6825ce4b5abb99371ae3e (patch)
tree0fa0e8502289a2f482391b9642c7ae18349cb9ca /lib
parentd758f45a14057f0b9517a1905d575d6b28b90bc2 (diff)
downloadpuppet-25a3f59be4a514629db6825ce4b5abb99371ae3e.tar.gz
puppet-25a3f59be4a514629db6825ce4b5abb99371ae3e.tar.xz
puppet-25a3f59be4a514629db6825ce4b5abb99371ae3e.zip
Fixing #558 - File checksums no longer refer to 'nosum'
It was only used in a method that apparently was not in use any more. Signed-off-by: Luke Kanies <luke@madstop.com>
Diffstat (limited to 'lib')
-rwxr-xr-xlib/puppet/type/file/checksum.rb34
1 files changed, 0 insertions, 34 deletions
diff --git a/lib/puppet/type/file/checksum.rb b/lib/puppet/type/file/checksum.rb
index 785ed0fee..f681a8ebe 100755
--- a/lib/puppet/type/file/checksum.rb
+++ b/lib/puppet/type/file/checksum.rb
@@ -37,11 +37,6 @@ Puppet::Type.type(:file).newproperty(:checksum) do
handlesum()
end
- newvalue(:nosum) do
- # nothing
- :nochange
- end
-
# If they pass us a sum type, behave normally, but if they pass
# us a sum type + sum, stick the sum in the cache.
munge do |value|
@@ -129,35 +124,6 @@ Puppet::Type.type(:file).newproperty(:checksum) do
cache(checktype())
end
- # Retrieve the cached sum
- def getcachedsum
- hash = nil
- unless hash = @resource.cached(:checksums)
- hash = {}
- @resource.cache(:checksums, hash)
- end
-
- sumtype = self.should
-
- if hash.include?(sumtype)
- #self.notice "Found checksum %s for %s" %
- # [hash[sumtype] ,@resource[:path]]
- sum = hash[sumtype]
-
- unless sum =~ /^\{\w+\}/
- sum = "{%s}%s" % [sumtype, sum]
- end
- return sum
- elsif hash.empty?
- #self.notice "Could not find sum of type %s" % sumtype
- return :nosum
- else
- #self.notice "Found checksum for %s but not of type %s" %
- # [@resource[:path],sumtype]
- return :nosum
- end
- end
-
# Calculate the sum from disk.
def getsum(checktype, file = nil)
sum = ""