Remove MODULECMD_ARG_OUTPUT argument type

Since the module command interface was expanded to include a JSON output
parameter, there is no longer a need for an output DCB. As the JSON can be
printed by both maxadmin and the REST API, this allows the removal of
explicit output formatting in module commands.
This commit is contained in:
Markus Mäkelä
2017-09-28 13:55:45 +03:00
parent da648387dd
commit 14d8b6a0df
9 changed files with 32 additions and 115 deletions

View File

@ -638,7 +638,7 @@ HttpResponse cb_modulecmd(const HttpRequest& request)
const MODULECMD* cmd = modulecmd_find_command(module.c_str(), identifier.c_str());
if (cmd && !modulecmd_requires_output_dcb(cmd))
if (cmd)
{
if ((!MODULECMD_MODIFIES_DATA(cmd) && verb == MHD_HTTP_METHOD_GET) ||
(MODULECMD_MODIFIES_DATA(cmd) && verb == MHD_HTTP_METHOD_POST))