Fix regression on checknagios

('EXCEPTION', "Critical : local variable 'maxage_hours' referenced before assignment") (tisbackup V8-108)
This commit is contained in:
htouvet 2018-02-16 10:05:19 +01:00
parent b082796a87
commit 769e61b78a

View File

@ -130,9 +130,6 @@ class tis_backup:
nagiosoutput = ''
for backup_item in self.backup_list:
if not sections or backup_item.backup_name in sections:
assert(isinstance(backup_item,backup_generic))
if not maxage_hours:
maxage_hours = backup_item.maximum_backup_age
(nagiosstatus,log) = backup_item.checknagios()
if nagiosstatus == nagiosStateCritical:
critical.append((backup_item.backup_name,log))