Handle events for unknown processes

This commit is contained in:
norohind 2022-11-13 17:33:15 +03:00
parent 97d7714d0b
commit 9a49e2750a
Signed by: norohind
GPG Key ID: 01C3BECC26FB59E1

View File

@ -226,6 +226,13 @@ class AudioController:
return
else:
try:
self.get_process(event.PID)
except KeyError:
logger.warning(f'Event for unknown process {event}')
return
if isinstance(event, Events.VolumeIncrement):
self.increment_volume(event.PID, event.increment)