Corrected bug causing crash when clearing the notifications from the tray