Put meta before data in the json responses.

This commit is contained in:
voussoir 2020-06-17 12:37:22 -07:00
parent 136a47bf10
commit 91ac2315e6

View file

@ -13,8 +13,8 @@ function _request(method, url, callback)
if (callback != null) if (callback != null)
{ {
var response = { var response = {
"data": JSON.parse(request.responseText), "meta": {},
"meta": {} "data": JSON.parse(request.responseText)
}; };
response["meta"]["request_url"] = url; response["meta"]["request_url"] = url;
response["meta"]["status"] = request.status; response["meta"]["status"] = request.status;