NSInternalInconsistencyException', reason: 'could not dequeue a view of kind: UICollectionElementKindCell with identifier restaurantCell - must register a nib or a class for the identifier or connect a prototype cell in a storyboard'

You should take this over to the Apple Developer Forums, because it's not a Swift language question.

Briefly, your code is asking to create cells with identifier "restaurantCell", but you haven't defined any cells with that identifier using any of the available ways of doing so.

Most likely, you have a prototype cell for this collection view in your storyboard that you've forgotten to set the identifier for.