From 6b301f738c5008fc63c7eada14a879d6c4030715 Mon Sep 17 00:00:00 2001 From: Reinaldo Araujo Barreto Junior Date: Wed, 6 Jul 2022 18:43:32 -0300 Subject: [PATCH] =?UTF-8?q?:hammer:=20APP=20#270=20corre=C3=A7=C3=A3o=20ex?= =?UTF-8?q?emplo?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- appexemplo_v2.0/api/api_controllers/SysinfoAPI.class.php | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/appexemplo_v2.0/api/api_controllers/SysinfoAPI.class.php b/appexemplo_v2.0/api/api_controllers/SysinfoAPI.class.php index 82f7f633..537fe0c1 100644 --- a/appexemplo_v2.0/api/api_controllers/SysinfoAPI.class.php +++ b/appexemplo_v2.0/api/api_controllers/SysinfoAPI.class.php @@ -22,8 +22,9 @@ public static function info() //-------------------------------------------------------------------------------- public static function getInfo(Request $request, Response $response, array $args) { - $result = self::info(); - $response = $response->withJson($result); - return $response; + $msg = self::info(); + $msgJson = json_encode($msg); + $response->getBody()->write( $msgJson ); + return $response->withHeader('Content-Type', 'application/json'); } } \ No newline at end of file