title: AVPlayer doesn't resume playback on endinterruption on iPhone but does so on iPad
body: <p>I'm writing a radio app for both iPhone and iPad and am running into some weird behaviour when handling pausing and playing the audio with interruptions. I'm using the AVAudioSessionDelegate methods <code>beginInterruption</code> and <code>endInterruption</code> to respectively <code>pause</code> and <code>play</code> the AVPlayer. Below is the relevant <code>play</code> code.</p>
  
  <p>Now, the following situations seem to happen consistently:</p>
  
  <ol>
  <li><strong>On iPad:</strong> If I force an interruption (Facetime call), <code>beginInterruption</code> is called as expected and playback stops. If the interruption stops, <code>endInterruption</code> is called as expected, and the playback resumes as expected.</li>
  <li><strong>On iPhone:</strong> Pressing the play and pause button, triggers <code>pause</code> and <code>play</code> exactly the same as <code>beginInterruption</code> and <code>endInterruption</code> would. Playback behaves as expected.</li>
  <li><strong>On iPhone:</strong> Forcing an interruption (by calling the phone), calls <code>endInterruption</code> as expected and playback pauses as expected. However, when the interruption is finished, <code>beginInterruption</code> is called as expected, <code>play</code> is called as expected, <em>it actually reaches and executes the <code>[self.player play]</code> line</em>, but playback <strong>does not resume!</strong> I hear nothing.</li>
  </ol>
  
  <p>Situation 3 above is extremely weird, so I'm wondering if I may have overlooked something. Any ideas?</p>
  
  <p><strong><code>Play</code> code</strong></p>
  
  <pre><code>- (void)play { 
  NSError* error = nil;
  AVKeyValueStatus keyStatus = [currentAsset statusOfValueForKey:@"tracks" error:&amp;error];
  if(error){
      DLog(@"Error %@", [error localizedDescription]);
  }
  else {
      DLog(@"Current Key Status: %i", keyStatus);
      if(keyStatus == AVKeyValueStatusLoaded){
          DLog(@"Continue playing source: %@", self.source);
          [[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:&amp;error];
          if (error) {
              DLog(@"Error during play while setting AVAudioSessionCategory: %@", [error localizedDescription]);
          }
          [[AVAudioSession sharedInstance] setActive:YES error:&amp;error];
          if (error) {
              DLog(@"Error during play while setting AVAudioSessionCategory: %@", [error localizedDescription]);
          }
          [[AVAudioSession sharedInstance] setDelegate:self];
          if(backgroundTaskID != UIBackgroundTaskInvalid){
              [[UIApplication sharedApplication] endBackgroundTask:backgroundTaskID];
          }
          backgroundTaskID = [[UIApplication sharedApplication] beginBackgroundTaskWithExpirationHandler:NULL];
  
          [self.player play];
          [self setStatus:kNPOMediaPlayerStatusPlaying];
      }
      else {
          DLog(@"PlaySource: %@", self.source);
          [self playSource:self.source];
      }
  }}
  </code></pre>