summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKrzysztof Wilczynski <krzysztof.wilczynski@linux.com>2011-04-26 00:00:58 +0100
committerKrzysztof Wilczynski <krzysztof.wilczynski@linux.com>2011-04-26 00:00:58 +0100
commitf87fcecdfb9fac33ac13952a6546b8ed7f673909 (patch)
tree6341742ab0b5c5373a220f909d707c6a76fcd890
parent28254bef6baa6ac9c1c26a2c58bdfd0548c7a553 (diff)
downloadpuppet-stdlib-f87fcecdfb9fac33ac13952a6546b8ed7f673909.tar.gz
puppet-stdlib-f87fcecdfb9fac33ac13952a6546b8ed7f673909.tar.bz2
Small re-factor to fact function.
Signed-off-by: Krzysztof Wilczynski <krzysztof.wilczynski@linux.com>
-rw-r--r--fact.rb6
1 files changed, 1 insertions, 5 deletions
diff --git a/fact.rb b/fact.rb
index 9522293..6e66ba6 100644
--- a/fact.rb
+++ b/fact.rb
@@ -24,14 +24,10 @@ module Puppet::Parser::Functions
# and empty string is as closest to actual undef as you we can get
# at this point in time ...
#
- result = (not result or result.empty?) ? '' : result
+ result = (result and not result.empty?) ? result : ''
return result
end
end
# vim: set ts=2 sw=2 et :
-
-notice fact('interfaces')
-notice fact('xyz')
-notice fact('')