MXS-1220: Fix resource self links
The top level resource self links pointed to the collection instead of the resource itself. The individual resoures now also have a links field that contains the self link to the resource. This should make navigation of the API easier as all objects have valid links in them.
This commit is contained in:
@ -453,6 +453,7 @@ static json_t* module_json_data(const LOADED_MODULE *mod, const char* host)
|
||||
|
||||
json_object_set_new(attr, CN_PARAMETERS, params);
|
||||
json_object_set_new(obj, CN_ATTRIBUTES, attr);
|
||||
json_object_set_new(obj, CN_LINKS, mxs_json_self_link(host, CN_MODULES, mod->module));
|
||||
|
||||
return obj;
|
||||
}
|
||||
|
Reference in New Issue
Block a user