title: NSInvalidArgumentException, reason: no object at index in section at index. UICollectionViewController and NSFetchedResultsController
body: <p>Trying to add a button "Add New" at the end of my <code>UICollecitonView</code>. 
  Working with <code>CoreData</code>. </p>
  
  <pre><code>func collectionView(_ collectionView: UICollectionView, cellForItemAt indexPath: IndexPath) -&gt; UICollectionViewCell {
      let cell = collectionView.dequeueReusableCell(withReuseIdentifier: "Cell", for: indexPath) as! CollectionCell
      configureCell(cell: cell, indexPath: indexPath)
  
      var numberOfItems = self.collectionView(self.collectionView, numberOfItemsInSection: 0)
  
      if (indexPath.row == numberOfItems - 1) {            
          var addCellButton = UIButton(frame: cell.frame)
          addCellButton.setTitle("Add", for: UIControlState.normal)
  
          cell.addSubview(addCellButton)
      }
      return cell
  } 
  
  func collectionView(_ collectionView: UICollectionView, numberOfItemsInSection section: Int) -&gt; Int {
  
      if let sections = controller.sections {
          let sectionInfo = sections[section]
          return sectionInfo.numberOfObjects + 1
      }
      return 0
  }
  </code></pre>
  
  <blockquote>
    <p>Error: 'NSInvalidArgumentException', reason: 'no object at index 3 in section at index 0'</p>
  </blockquote>
  
  <p>Do I need to check bounds of <code>NSFetchedResultsController</code>?
  As proposed here: <a href="https://stackoverflow.com/questions/25049923/terminating-app-due-to-uncaught-exception-nsinternalinconsistencyexception-re">Terminating app due to uncaught exception &#39;NSInternalInconsistencyException&#39;, reason: &#39;no object at index 3 in section at index 0&#39;</a> </p>