Skip to content

Commit 8baa558

Browse files
committed
fix import zones
1 parent b9cbe8e commit 8baa558

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

modules/utils.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,10 @@ def check_and_import_zones(api):
4040
g.logger.Debug(4,'Not importing zones for monitor:{} as the monitor specific section says no'.format(mid))
4141
continue
4242
# else if global is no, and there is no local, don't import
43-
elif g.config['import_zm_zones'] == 'no' and mid not in g.monitor_config:
43+
elif g.config['import_zm_zones'] == 'no' and (mid not in g.monitor_config or not g.monitor_config[mid].get('import_zm_zones')):
4444
g.logger.Debug(4,'Not importing zone:{} for monitor:{} as the global setting says no and there is no local override'.format(item['Zone']['Name'], mid))
4545
continue
46+
4647
# At this stage, global is 'yes' and local is either unspecified or has 'yes'
4748
if not mid in g.monitor_config:
4849
g.monitor_config[mid]={}

0 commit comments

Comments
 (0)