chg: [internal] Faster checking if warninglist already exists for event

pull/6112/head
Jakub Onderka 2020-07-13 17:53:09 +02:00
parent 60207d9a80
commit c9b024e220
1 changed files with 1 additions and 1 deletions

View File

@ -364,7 +364,7 @@ class Warninglist extends AppModel
} else {
$object['warnings'][$result][] = $list['Warninglist']['name'];
}
if (empty($eventWarnings) || !in_array($list['Warninglist']['name'], $eventWarnings)) {
if (!isset($eventWarnings[$list['Warninglist']['id']])) {
$eventWarnings[$list['Warninglist']['id']] = $list['Warninglist']['name'];
}
}