Fixed glitch with iOS notifications when the app is in the foreground