fix maybe respondd module

This commit is contained in:
Martin/Geno 2018-08-05 20:05:55 +02:00
parent 69ff5a62ca
commit c001c35f25
No known key found for this signature in database
GPG Key ID: 9D7D3C6BFF600C6A
1 changed files with 4 additions and 0 deletions

View File

@ -140,6 +140,8 @@ struct json_object *respondd_provider_nodeinfo(void) {
int ubus_ret = ubus_fetch("get_config", cb_config); int ubus_ret = ubus_fetch("get_config", cb_config);
if (ubus_ret) { if (ubus_ret) {
json_object_object_add(wifictld, "error", json_object_new_int(ubus_ret)); json_object_object_add(wifictld, "error", json_object_new_int(ubus_ret));
json_object_object_add(ret, "wifictld", wifictld);
return ret;
} }
if (!json_config_store) { if (!json_config_store) {
@ -161,6 +163,8 @@ struct json_object *respondd_provider_statistics(void) {
int ubus_ret = ubus_fetch("get_clients", cb_client); int ubus_ret = ubus_fetch("get_clients", cb_client);
if (ubus_ret) { if (ubus_ret) {
json_object_object_add(wifictld, "error", json_object_new_int(ubus_ret)); json_object_object_add(wifictld, "error", json_object_new_int(ubus_ret));
json_object_object_add(ret, "wifictld", wifictld);
return ret;
} }
if (!json_client_store) { if (!json_client_store) {