I have the next structure:
So, how you can see, I apply segue from the left top controller to GalleryViewController and want to pass some values through the segue, for that I do:
if segue.identifier == "goToGalleryVCFromRestaurant" {
let galleryViewController = segue.destination as! GalleryViewController
galleryViewController.photos = self.photos
}
but because of my GalleryViewController is embedded in UINavController this part will never be executed let galleryViewController = segue.destination as! GalleryViewController
. How can I fix that?