Inconsistent JSON Format Returned
aalshibily opened this issue · 2 comments
Hi,
I was playing around with the API and I noticed that for a single random joke and a random type joke I was getting JSON but in inconsistent formats.
Example:
Totally random
via [https://official-joke-api.appspot.com/jokes/random](this link)
{"id":364,"type":"general","setup":"Why do pirates not know the alphabet?","punchline":"They always get stuck at \"C\"."}
Type Random
via [https://official-joke-api.appspot.com/jokes/programming/random](this link)
[{"id":28,"type":"programming","setup":"To understand what recursion is...","punchline":"You must first understand what recursion is"}]
It's probably a minor fix but I just wanted to point it out.
Love the API btw!
This problem is fixed on https://github.com/UltiRequiem/joke
I commented on this inconsistent format here: #48. Unfortunately, I'm deciding to keep the format to support a course that I made, that is using this inconsistent format. Future client-side applications can get around this by implementing a condition that recognizes this endpoint's odd return format.