Fix CliResetSessionTest by allowing empty POST fields to be defined in the curl options

This commit is contained in:
lenaick.moreira
2026-04-01 10:35:59 +02:00
parent 3cdadf3c6e
commit 9a2c8f10bf

View File

@@ -676,7 +676,7 @@ abstract class ItopTestCase extends KernelTestCase
curl_setopt_array($ch, $aCurlOptions);
if ($this->IsArrayOfArray($aPostFields)) {
curl_setopt($ch, CURLOPT_POSTFIELDS, http_build_query($aPostFields));
} elseif (!empty($aPostFields)) {
} else {
curl_setopt($ch, CURLOPT_POSTFIELDS, $aPostFields);
}