- controlapi/statfs: simplify error handling

This commit is contained in:
svenhoefer
2016-02-20 23:10:17 +01:00
parent e407ef5a98
commit 0927756467

View File

@@ -3289,13 +3289,7 @@ void CControlAPI::StatfsCGI(CyhookHandler *hh) {
hh->WriteLn(result); hh->WriteLn(result);
} }
else else
{ hh->SendError("statfs failed");
if (outType == json)
hh->WriteLn(json_out_error("statfs failed"));
else
hh->SendError();
}
} }
//----------------------------------------------------------------------------- //-----------------------------------------------------------------------------