diff --git a/modules/timepoint_list/php/timepoint_list.class.inc b/modules/timepoint_list/php/timepoint_list.class.inc index a39b6437df8..b032cdf2dfa 100644 --- a/modules/timepoint_list/php/timepoint_list.class.inc +++ b/modules/timepoint_list/php/timepoint_list.class.inc @@ -328,7 +328,7 @@ class Timepoint_List extends \NDB_Menu protected function handleDelete( ServerRequestInterface $request ): ResponseInterface { - $body = $request->getBody(); + $body = $request->getBody()->getContents(); $jsonBody = json_decode($body, true); $id = null; if (is_array($jsonBody) && array_key_exists('sessionID', $jsonBody)) { @@ -353,7 +353,7 @@ class Timepoint_List extends \NDB_Menu */ protected function handlePost(ServerRequestInterface $request): ResponseInterface { - $body = $request->getBody(); + $body = $request->getBody()->getContents(); $jsonBody = json_decode($body, true); // Check if $jsonBody is an array before accessing its keys $id = $date = $subproject = null; diff --git a/modules/timepoint_list/test/timepoint_listTest.php b/modules/timepoint_list/test/timepoint_listTest.php index feca55c0a17..cbd1bb3e5f6 100644 --- a/modules/timepoint_list/test/timepoint_listTest.php +++ b/modules/timepoint_list/test/timepoint_listTest.php @@ -40,8 +40,8 @@ class TimepointListIntegrationTest extends LorisIntegrationTestWithCandidate '-', '', '', - '', - 'Edit Archive', + '', + 'Edit Archive', ]; /**