I have problem with this code:
func collectionView(collectionView: UICollectionView, didSelectItemAtIndexPath indexPath: NSIndexPath) {
self.performSegue
The following code should work well for you :
override func prepareForSegue(segue: UIStoryboardSegue, sender: AnyObject?) {
if segue.identifier == "showDetailsSegue" {
let detailsVC = segue.destinationViewController as! DetailsViewController
let cell = sender as! StampsCollectionViewCell
let indexPaths = self.couponsCollectionView.indexPathForCell(cell)
var thisCoupon = self.userCoupons[indexPaths!.row] as UserCoupons
detailsVC.userCoupon = thisCoupon
detailsVC.pinArray = self.pinArray
detailsVC.userStamp = self.userStamps[indexPaths!.row]
}
}
Update : Please check the incoming data from the server if its correct or not and it might work !