title: No UICollectionViewLayoutAttributes instance for layoutAttributesForSupplementaryElementOfKind?
body: <pre><code>2014-07-24 11:50:15.925  *** Assertion failure in -[UICollectionViewData layoutAttributesForSupplementaryElementOfKind:atIndexPath:], /SourceCache/UIKit/UIKit-2935.137/UICollectionViewData.m:787
  
  2014-07-24 11:50:15.927  *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'no UICollectionViewLayoutAttributes instance for -layoutAttributesForSupplementaryElementOfKind: UICollectionElementKindSectionFooter at path &lt;NSIndexPath: 0xc000000000000016&gt; {length = 2, path = 0 - 0}'
  </code></pre>
  
  <p>i have this error message occurs when i scrolling my collection view and i totally loss in mind how could this happen ? any suggestion to help are thankful.</p>
  
  <p>The register </p>
  
  <pre><code>[self.collectionView registerClass:[CollectionViewFooter class]
              forSupplementaryViewOfKind:UICollectionElementKindSectionFooter withReuseIdentifier:@"CollectionViewFooter"];
  </code></pre>
  
  <p>The Delegate Method</p>
  
  <pre><code>- (UICollectionReusableView *)collectionView:(UICollectionView *)collectionView viewForSupplementaryElementOfKind:(NSString *)kind atIndexPath:(NSIndexPath *)indexPath
  {
      //declare the reusable view of header and footer
      UICollectionReusableView *reusableview = nil;
  
      CollectionViewFooter *footer=nil;
  
  
      if([kind isEqual:UICollectionElementKindSectionFooter])
      {
          footer = [collectionView dequeueReusableSupplementaryViewOfKind:kind withReuseIdentifier:@"CollectionViewFooter" forIndexPath:indexPath];
  
          //attach the footer to reusable view
          reusableview = footer;
      }
  
  
      return reusableview;
  }
  </code></pre>
  
  <p>Check by break point, error occur when reach to line
   <code>[self.collectionView performBatchUpdates:^{</code></p>