Skip to content
Commit 02e01b51 authored by Lei YU's avatar Lei YU Committed by Ed Tanous
Browse files

http_connection: Allow empty json objects



Currently http_connection will produce empty body in the response if the
res.jsonValue is empty, including empty array, object.

This makes the output confusing in case a response does contain an empty
object or array.

Change the code to print the json object even if it's empty object or
array, so that the output is consistent with the `res.jsonValue`.

Tested: With an OEM URL that returns empty array depending on the system
        config, the response becomes `[]` instead of empty.

Signed-off-by: default avatarLei YU <yulei.sh@bytedance.com>
Change-Id: Ie97378a2cffce7b1fd6586a56b6cfa7d5c476dc1
parent 8d01836c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment