Fixes potential crash when launching games

This commit is contained in:
Riley Testut 2018-11-26 16:55:23 -08:00
parent ca4ccfc3ae
commit 1f298f8e79

View File

@ -189,8 +189,8 @@ private extension GameCollectionViewController
//MARK: - Data Source
func prepareDataSource()
{
self.dataSource.cellConfigurationHandler = { [unowned self] (cell, item, indexPath) in
self.configure(cell as! GridCollectionViewCell, for: indexPath)
self.dataSource.cellConfigurationHandler = { [weak self] (cell, item, indexPath) in
self?.configure(cell as! GridCollectionViewCell, for: indexPath)
}
self.dataSource.prefetchHandler = { (game, indexPath, completionHandler) in