Making JSON more readable

This commit is contained in:
jf-cbd
2025-02-28 16:35:59 +01:00
parent 783fa01fc9
commit e8c622a15d
2 changed files with 2 additions and 2 deletions

View File

@@ -718,7 +718,7 @@ class CoreServices implements iRestServiceProvider, iRestInputSanitizer
}
break;
}
return json_encode($aJsonData, JSON_UNESCAPED_SLASHES|JSON_PRETTY_PRINT);
return json_encode($aJsonData, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT);
}
/**

View File

@@ -286,7 +286,7 @@ if (MetaModel::GetConfig()->Get('log_rest_service'))
$oLog->SetTrim('message', $sMessage);
$oLog->Set('code', $oResult->code);
$oResult->SanitizeContent();
$oLog->SetTrim('json_output', json_encode($oResult));
$oLog->SetTrim('json_output', json_encode($oResult, JSON_UNESCAPED_SLASHES | JSON_PRETTY_PRINT));
$oLog->DBInsertNoReload();
$oKPI->ComputeAndReport('Log inserted');