Answer the question
In order to leave comments, you need to log in
How to add additional check for Json Response method?
Friends, a hint is needed on how to add one more check to the JSON Response method, before the loop / receiving data
. The method itself looks like this
func mediaImage() {
if let mediaImages = json["......."]["......._media"]["....."]["......."][].array {
for images in mediaImages {
self.........append(images["......."]["......."]["......."].stringValue)
}
print("Media Images = \(self........)")
} else {
print("No Media Images")
}
}
Answer the question
In order to leave comments, you need to log in
Let's start with the fact that you are using the library as I understood SwiftyJSON? What you have highlighted in blue on the screen is not clear how to check, show what's inside.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question