summaryrefslogtreecommitdiffstats
path: root/lib/facter.rb
diff options
context:
space:
mode:
authorJames Turnbull <james@lovedthanlost.net>2010-04-24 15:46:45 +1000
committerJames Turnbull <james@lovedthanlost.net>2010-04-24 15:46:45 +1000
commit802e6c24a0968deb0b45402d73c850f045b70c46 (patch)
tree1fe64ebf25879563da63e1e406213aa5845b2ccb /lib/facter.rb
parent2f016f387367d6e52504194098333d1692e33c67 (diff)
downloadfacter-802e6c24a0968deb0b45402d73c850f045b70c46.tar.gz
facter-802e6c24a0968deb0b45402d73c850f045b70c46.tar.xz
facter-802e6c24a0968deb0b45402d73c850f045b70c46.zip
Fixed #3542 - Ruby 1.9: broken unittest, String#each no longer exists
Thanks to Jos Backus for the fix.
Diffstat (limited to 'lib/facter.rb')
-rw-r--r--lib/facter.rb1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/facter.rb b/lib/facter.rb
index ac06f68..46e2e99 100644
--- a/lib/facter.rb
+++ b/lib/facter.rb
@@ -180,6 +180,7 @@ module Facter
def self.warn(msg)
if Facter.debugging? and msg and not msg.empty?
+ msg = [msg] unless msg.respond_to? :each
msg.each { |line| Kernel.warn line }
end
end