title: Getting wrong playback state in MP Music Player Controller in ios 5
body: <p>i am getting wrong playback state in MP music player.
  while playing a song i am getting pause state.
  My app is working fine in ios 4.but i am having this issue in ios 5.
  can anybody Help me ??</p>
  
  <p>My code is here.</p>
  
  <pre><code>[musicPlayer stop];
  if (userMediaItemCollection)
  {
     userMediaItemCollection=nil; 
  }
  musicPlayer.nowPlayingItem=nil;
  
  userMediaItemCollection=[MPMediaItemCollection collectionWithItems:[mediaItemCollection    items]];
  
  [musicPlayer setQueueWithItemCollection:userMediaItemCollection];
  [musicPlayer setNowPlayingItem:    
  [[userMediaItemCollectionitems]objectAtIndex:indexOfCurrentObject]];
  [self enablePrevAndNextButtons];
  
  [musicPlayer play];        
  }
  
  -(void)playbackStateDidChanged:(NSNotification *)notification
  {
  
   if (musicPlayer.playbackState!=MPMusicPlaybackStatePlaying)
   {
      [playPauseButton setBackgroundImage:[UIImage imageNamed:@"play_iPad.png"] forState:UIControlStateNormal];
   }
   else if(musicPlayer.playbackState==MPMusicPlaybackStatePlaying)
   {
      [playPauseButton setBackgroundImage:[UIImage imageNamed:@"pause_iPad.png"] forState:UIControlStateNormal];
   }
  </code></pre>