fix: maintenance heredity

This commit is contained in:
Peace 2023-05-31 21:29:20 +02:00
parent 2b46da0f47
commit 56f448bfe5
No known key found for this signature in database
GPG Key ID: 0EF6B46E172B739F
1 changed files with 4 additions and 4 deletions

View File

@ -1371,11 +1371,11 @@ class Monitor extends BeanModel {
if (maintenance && await maintenance.isUnderMaintenance()) {
return true;
}
}
const parent = await Monitor.getParent(monitorID);
if (parent != null) {
return await Monitor.isUnderMaintenance(parent.id);
}
const parent = await Monitor.getParent(monitorID);
if (parent != null) {
return await Monitor.isUnderMaintenance(parent.id);
}
return false;