Skip to content

Commit

Permalink
Added suspensionBehavior parameter to addObserver. This should fix no…
Browse files Browse the repository at this point in the history
…tifications sometimes getting delayed for a couple of seconds after a song change.
  • Loading branch information
ksuther committed Dec 11, 2013
1 parent fa20caf commit a38281c
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion Spotify Notifications/AppDelegate.m
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,8 @@ - (void)applicationDidFinishLaunching:(NSNotification *)notification{
[[NSDistributedNotificationCenter defaultCenter] addObserver:self
selector:@selector(eventOccured:)
name:@"com.spotify.client.PlaybackStateChanged"
object:nil];
object:nil
suspensionBehavior:NSNotificationSuspensionBehaviorDeliverImmediately];

[self setIcon];

Expand Down

0 comments on commit a38281c

Please sign in to comment.