From 75be89b2167e3d3b29012f3793ac980400767f3e Mon Sep 17 00:00:00 2001
From: gimmy <gheorghe.popescu@puppet.com>
Date: Fri, 13 Mar 2020 14:43:10 +0200
Subject: [PATCH] (maint) remove fact.flush

---
 lib/puppet/util/firewall.rb | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

diff --git a/lib/puppet/util/firewall.rb b/lib/puppet/util/firewall.rb
index 9695444..676bcf8 100644
--- a/lib/puppet/util/firewall.rb
+++ b/lib/puppet/util/firewall.rb
@@ -180,9 +180,7 @@ module Puppet::Util::Firewall
 
     # Older iptables-persistent doesn't provide save action.
     if os_key == 'Debian'
-      # 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.fact(:iptables_persistent_version).flush
+      Facter.fact(:iptables_persistent_version)
       persist_ver = Facter.value(:iptables_persistent_version)
       if persist_ver && Puppet::Util::Package.versioncmp(persist_ver, '0.5.0') < 0
         os_key = 'Debian_manual'
-- 
2.45.2