diff options
| author | Markus Roberts <Markus@reality.com> | 2010-11-04 13:53:23 -0700 |
|---|---|---|
| committer | James Turnbull <james@lovedthanlost.net> | 2010-11-12 15:02:00 +1100 |
| commit | b15231df5842df2ea83b779b22e6756e51bc39d0 (patch) | |
| tree | 34978db4a199ccca92e35c66e154851bc60fff27 /lib/puppet/provider | |
| parent | ea435a43dc97487d054271a9efb208f361408339 (diff) | |
Fix for #4299 -- Don't require which
We already had an internal implementation of which hiding under an assumed
name (Puppet::Util.binary); this commit calls it out of hiding and uses it
consisantly.
Diffstat (limited to 'lib/puppet/provider')
| -rw-r--r-- | lib/puppet/provider/confine/exists.rb | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/lib/puppet/provider/confine/exists.rb b/lib/puppet/provider/confine/exists.rb index 085118b2a..09f94dfd9 100644 --- a/lib/puppet/provider/confine/exists.rb +++ b/lib/puppet/provider/confine/exists.rb @@ -6,10 +6,7 @@ class Puppet::Provider::Confine::Exists < Puppet::Provider::Confine end def pass?(value) - if for_binary? - return false unless value = binary(value) - end - value and FileTest.exist?(value) + value && (for_binary? ? which(value) : FileTest.exist?(value)) end def message(value) |
