diff --git a/config/firewall/rules.pl b/config/firewall/rules.pl index c72b0129d..57abbdf05 100644 --- a/config/firewall/rules.pl +++ b/config/firewall/rules.pl @@ -110,8 +110,11 @@ sub main { # Flush exported locations. &GeoIP::flush_exported_locations(); - # Export required locations. - &GeoIP::export_locations(\@locations_to_export); + # Check if there are any locations to export. + if (@locations_to_export) { + # Export required locations. + &GeoIP::export_locations(\@locations_to_export); + } # Prepare firewall rules. if (! -z "${General::swroot}/firewall/input"){