From: Jonathan Tripathy Date: Wed, 10 Feb 2016 10:49:15 +0000 (+0000) Subject: Made Facter flushing specific to a single fact. X-Git-Tag: 1.8.0~4^2 X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=a9b8f4dc3446c3e36c93d25b3c2274e9143416d1;p=puppet-modules%2Fpuppetlabs-firewall.git Made Facter flushing specific to a single fact. --- diff --git a/lib/puppet/util/firewall.rb b/lib/puppet/util/firewall.rb index 8acbd46..d094b4c 100644 --- a/lib/puppet/util/firewall.rb +++ b/lib/puppet/util/firewall.rb @@ -160,9 +160,9 @@ module Puppet::Util::Firewall # Older iptables-persistent doesn't provide save action. if os_key == 'Debian' - # We need to call Facter.flush to clear Facter cache as it's possible the cached value will be nil due to the fact + # We need to call flush to clear Facter cache as it's possible the cached value will be nil due to the fact # that the iptables-persistent package was potentially installed after the initial Fact gathering. - Facter.flush + Facter.fact(:iptables_persistent_version).flush persist_ver = Facter.value(:iptables_persistent_version) if (persist_ver and Puppet::Util::Package.versioncmp(persist_ver, '0.5.0') < 0) os_key = 'Debian_manual'