                 case .Horizontal:
                     let delta = newBounds.origin.x - collectionView.bounds.origin.x
                     let touchPoint = collectionView.panGestureRecognizer.locationInView(collectionView)
-                    for (index, behavior) in behaviors.enumerate() {
+                    for behavior in behaviors {
                         let yDistanceFromTouch = fabs(touchPoint.y - behavior.anchorPoint.y)
                         let xDistanceFromTouch = fabs(touchPoint.x - behavior.anchorPoint.x)
                         let scrollResistance = (yDistanceFromTouch + xDistanceFromTouch) / 1500

                case .Vertical:
                    let delta = newBounds.origin.y - collectionView.bounds.origin.y
                    let touchPoint = collectionView.panGestureRecognizer.locationInView(collectionView)
                    for (index, behavior) in behaviors.enumerate() {
                        let yDistanceFromTouch = fabs(touchPoint.y - behavior.anchorPoint.y)
                        let xDistanceFromTouch = fabs(touchPoint.x - behavior.anchorPoint.x)
                        let scrollResistance = (yDistanceFromTouch + xDistanceFromTouch) / 1500

        return super.layoutAttributesForElementsInRect(rect)
    }

    public override func layoutAttributesForItemAtIndexPath(indexPath: NSIndexPath) -> UICollectionViewLayoutAttributes? {
        if let attributes = dynamicAnimator?.layoutAttributesForCellAtIndexPath(indexPath) {
            return attributes
        }
