|
|
|
|
|
by nailer
236 days ago
|
|
get_response().json()
is ideal, and I'm assuming yoiu're writing an HTTP wrapper since decoding JSON is a sensible default.If you need to add an intermediary variable, name it as clearly as possible: raw_response = get_response()
response = raw_response.json()
|
|
I strive to write code that reduces cognitive load. To me, putting it in a temp variable is more of habit of old languages, mixed with a bit of cargo cult.