title: Source type 1 not available
body: <p>I have an app for iPhone and iPad, and when I try to load an <code>UIPickerViewController</code> in a <code>UIPopoverController</code> for iPad I get the Exception "Source type 1 not available".
  getting the problem even though using the device.</p>
  
  <pre><code>@try {
      if ([UIImagePickerController isSourceTypeAvailable:UIImagePickerControllerSourceTypeCamera])  {
          UIImagePickerController *imagePicker = [[UIImagePickerController alloc] init];
  
          imagePicker.sourceType = UIImagePickerControllerSourceTypeCamera;
          imagePicker.delegate = self;
          imagePicker.allowsEditing = NO;
  
          self.tempComp = component;
          if ([[UIDevice currentDevice] userInterfaceIdiom] == UIUserInterfaceIdiomPhone) {
              [self presentModalViewController:imagePicker animated:YES];
          }else {
              // We are using an iPad
              popoverController=[[UIPopoverController alloc] initWithContentViewController:imagePicker];
              popoverController.delegate = self;
  
              [popoverController presentPopoverFromRect:component.bounds inView:component permittedArrowDirections:UIPopoverArrowDirectionAny animated:YES];
          }
      }else{
          UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Camera Non Disponibile" message:@"La camera non è disponibile" delegate:self cancelButtonTitle:@"Ok" otherButtonTitles: nil];
          [alert show];
      }
  }
  @catch (NSException *exception) {
      NSLog(@"Cattura eccezione %@", exception);
      UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Eccezione" message:[NSString stringWithFormat:@"%@", exception] delegate:self cancelButtonTitle:@"Ok" otherButtonTitles: nil];
      [alert show];
  }
  </code></pre>