-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
hi I was just going through this tutorial on YouTube and noticed the image for the bob's burgers characters return a malformed image URL.
at https://svelte.fun/api/bobs-burgers/characters/1
I get
{"id":1,"name":""Dottie Minerva"","image":"//svelte.fun/bobs-burgers/images/1.jpg","gender":"Female","hairColor":"Blonde","occupation":"Student at Wagstaff School","firstEpisode":""The Kids Run the Restaurant"","voicedBy":"Wendy Molyneux","url":"https://bobsburgers-api.herokuapp.com/characters/1","wikiUrl":"https://bobs-burgers.fandom.com/wiki/%22Dottie_Minerva%22","relatives":[]}
and was expecting the image url to be https://svelte.fun/bobs-burgers/images/1.jpg
I did a fix on my side
characters = characters.map(character => ({
...character,
image: character.image.startsWith('//') ? 'https:' + character.image : character.image
}));
but would be great to not need that
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels