title: When I am moving cells in UITableView, I can only drag last but one cell to only last position
body: <p>I have a problem with my UITableViewController. I have list of objects that I want to move.</p>
  
  <p>The thing is that I am able only to move the last of one cell to the last position, not any other of cells. I think it is just simple code, but I really do not know, what I am missing.</p>
  
  <p>I do not want to delete or insert objects, I just want to move them. Thanks for any help.</p>
  
  <p>Here is my code:</p>
  
  <p><strong>myListOfObjects</strong> is NSMutableArray of my custom objects</p>
  
  <pre><code>- (void)viewDidLoad
  {
      [super viewDidLoad];
  
      [self.tableView registerCellClassWithNib:[MyCustomCell class]];
      self.tableView.separatorStyle = UITableViewCellSeparatorStyleNone;
      [self.tableView setEditing:YES];
  }
  
  - (NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section
  {
      return [self.myListOfObjects count];
  }
  
  - (UITableViewCell *)tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath
  {
      MyCustomCell *cell = [tableView dequeueReusableCellWithIdentifier:[MyCustomCell className]
                                                            forIndexPath:indexPath];
  
      cell.myObject = self.myListOfObjects[indexPath.row];
  
      return cell;
  }
  
  - (BOOL)tableView:(UITableView *)tableView canEditRowAtIndexPath:(NSIndexPath *)indexPath
  {
      return YES;
  }
  
  - (void)tableView:(UITableView *)tableView moveRowAtIndexPath:(NSIndexPath *)fromIndexPath toIndexPath:(NSIndexPath *)toIndexPath
  {
      [self.myListOfObjects exchangeObjectAtIndex:toIndexPath.row withObjectAtIndex:fromIndexPath.row];
  }
  
  - (BOOL)tableView:(UITableView *)tableView canMoveRowAtIndexPath:(NSIndexPath *)indexPath
  {
      return YES;
  }
  
  - (UITableViewCellEditingStyle)tableView:(UITableView *)tableView editingStyleForRowAtIndexPath:(NSIndexPath *)indexPath
  {
      return UITableViewCellEditingStyleNone;
  }
  
  - (BOOL)tableView:(UITableView *)tableview shouldIndentWhileEditingRowAtIndexPath:(NSIndexPath *)indexPath
  {
      return NO;
  }
  </code></pre>