This is a companion discussion topic for the original entry at https://www.raywenderlich.com/10376245-networking-with-urlsession/lessons/31
This is a companion discussion topic for the original entry at https://www.raywenderlich.com/10376245-networking-with-urlsession/lessons/31
FYI
This NEVER WORKS if you follow the video instructions as told.
So the Download Material βstarterβ actually had the bogus attribute in the JSON.
It would be better to make it an OPTIONAL in the starter folder and then have folks remove the ? to blow up the JSON parser.
So for example this will work:
struct ArtistInfo: Codable {
let biography: String
let photo: String
let totalAlbums: Int?
}
Then ask the student to remove the β?β to force that field in your JSON result.
Enjoying the book!
Thanks