title: Passing via segue, PFObject crash Parse.com
body: <p>I am lost with segue. I tried to do it through <a href="https://www.parse.com/questions/pfquerytableviewcontroller-segue" rel="nofollow noreferrer">this tutorial</a>.</p>
  
  <p>Everything is working but only one line write me error and I don`t know how to fix it.
  Image with error:</p>
  
  <p><img src="https://i.stack.imgur.com/Fmczv.jpg" alt=""></p>
  
  <p>TableViewController.h</p>
  
  <pre><code>#import &lt;UIKit/UIKit.h&gt;
  #import "Parse/Parse.h"
  #import "CustomCell.h"
  #import "DetailViewController.h"
  
  @interface TableViewController : UITableViewController &lt;UITableViewDelegate,UISearchDisplayDelegate, UISearchBarDelegate&gt;  {
  
      NSArray *colorsArray;
      NSArray *searchResults;
  
  }
  
  @property (strong, nonatomic) IBOutlet UITableView *colorsTable;
  @property (strong, nonatomic) IBOutlet UISearchBar *searchBar;
  @property (strong, nonatomic) IBOutlet UISearchDisplayController *searchBarController;
  
  
  @end
  </code></pre>
  
  <p>TableViewController.m</p>
  
  <pre><code>#import "TableViewController.h"
  #import "CustomCell.h"
  #import "DetailViewController.h"
  
  
  @interface TableViewController (){
  }
  
  
  
  @end
  @implementation TableViewController
  
  
  @synthesize colorsTable;
  
  - (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender
  {    if ([segue.identifier isEqualToString:@"displayDetail"]){
  
  
          NSIndexPath *indexPath = [self.tableView indexPathForSelectedRow];
          PFObject *object = [self.objects objectAtIndex:indexPath.row];
  
  
  
          UINavigationController *nav = [segue destinationViewController];
          DetailViewController *detailViewController = (DetailViewController *) nav.topViewController;
          detailViewController.exam = object;
      }
  }
  
  
  
  - (void) retrieveFromParse {
  
      PFQuery *retrieveColors = [PFQuery queryWithClassName:@"Hracky1"];
      [retrieveColors findObjectsInBackgroundWithBlock:^(NSArray *objects, NSError *error) {
          if (!error) {
              colorsArray= [[NSArray alloc] initWithArray:objects];
          }
          [colorsTable reloadData];
  
      }];
      [self.colorsTable reloadData];
      [self.refreshControl endRefreshing];
  }
  
  - (id)initWithStyle:(UITableViewStyle)style
  {
      self = [super initWithStyle:style];
      if (self) {
          // Custom initialization
      }
      return self;
  }
  
  
  - (void)viewDidLoad
  {
      [super viewDidLoad];
  
      [self performSelector:@selector(retrieveFromParse)];
  
      UIRefreshControl *refreshControl = [[UIRefreshControl alloc] init];
  
      self.refreshControl = refreshControl;
  
      [refreshControl addTarget:self action:@selector(retrieveFromParse) forControlEvents:UIControlEventValueChanged];
  
  }
  
  - (void)didReceiveMemoryWarning
  {
      [super didReceiveMemoryWarning];
      // Dispose of any resources that can be recreated.
  }
  
  #pragma mark - Table view data source
  
  - (NSInteger)numberOfSectionsInTableView:(UITableView *)tableView
  {
      // Return the number of sections.
      return 1;
  }
  
  - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
  {
      // Return the number of rows in the section.
      return colorsArray.count;
  }
  
  - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
  {
      static NSString *CellIdentifier = @"colorsCell";
  
      CustomCell *cell = [tableView dequeueReusableCellWithIdentifier:CellIdentifier];
  
      PFObject *tempObject = [colorsArray objectAtIndex:indexPath.row];;
  
  
  
       [cell.imageview setFile: [tempObject objectForKey:@"ImageURL"]];
  
  
      [cell.imageview loadInBackground];
  
  
      cell.cellTitle.text = [tempObject objectForKey:@"cellTitle"];
      cell.cellDescript.text = [tempObject objectForKey:@"cellDescript"];
  
  
  
      return cell;
  }
  
  
  
  @end
  </code></pre>
  
  <p>DetailedViewController.h</p>
  
  <blockquote>
  <pre><code>#import &lt;UIKit/UIKit.h&gt;
  #import "Parse/Parse.h"
  
  @interface DetailViewController : UIViewController &lt;UITextViewDelegate&gt;
  
  @property (nonatomic, strong) PFObject *exam;
  @property (nonatomic, strong) IBOutlet UITextView *descriptext;
  @end
  </code></pre>
  </blockquote>
  
  <p>DetailViewcontrolled.m</p>
  
  <blockquote>
  <pre><code>#import "DetailViewController.h"
  #import "Parse/Parse.h"
  #import "TableViewController.h"
  
  @interface DetailViewController ()
  
  @end
  
  @implementation DetailViewController
  
  
  - (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
  {
      self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
      if (self) {
          // Custom initialization
      }
      return self;
  }
  
  - (void)viewDidLoad
  {
      [super viewDidLoad];{
  
     self.descriptext.text = [self.exam objectForKey:@"TextView"];
      }
  
  }
  
  
  
  
  - (void)didReceiveMemoryWarning
  {
      [super didReceiveMemoryWarning];
      // Dispose of any resources that can be recreated.
  }
  
  @end
  </code></pre>
  </blockquote>