 
 extension DataSource: UICollectionViewDelegate {
     public func collectionView(_ collectionView: UICollectionView, willDisplay cell: UICollectionViewCell, forItemAt indexPath: IndexPath) {
+        guard let middleware = options.middleware else { return }
         for middleware in middleware {
             middleware.apply(cell, indexPath, self.sections)
         }

            }
        }
    }
}



    public convenience init(items: [Item], onReorder: ReorderBlock? = nil, onScroll: ScrollBlock? = nil) {
        self.init(
            sections: [Section(items: items)],
            options: Options(onReorder: onReorder, onScroll: onScroll, middleware: nil)
        )
    }

