mirror of https://github.com/commaai/openpilot.git
parent
08212107e8
commit
75d00872e8
|
@ -63,10 +63,7 @@ class Events:
|
|||
self.events = self.static_events.copy()
|
||||
|
||||
def any(self, event_type: str) -> bool:
|
||||
for e in self.events:
|
||||
if event_type in EVENTS.get(e, {}).keys():
|
||||
return True
|
||||
return False
|
||||
return any(event_type in EVENTS.get(e, {}) for e in self.events)
|
||||
|
||||
def create_alerts(self, event_types: List[str], callback_args=None):
|
||||
if callback_args is None:
|
||||
|
|
Loading…
Reference in New Issue