From 19c7db4164a3f12b1cd880b720e048c9bb70d4e0 Mon Sep 17 00:00:00 2001 From: "CHIEFSOFT\\ameye" Date: Tue, 20 Feb 2024 14:01:35 -0500 Subject: [PATCH] log message --- www-api/app/Controllers/Home.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/www-api/app/Controllers/Home.php b/www-api/app/Controllers/Home.php index e8d556dc..977c0c2b 100644 --- a/www-api/app/Controllers/Home.php +++ b/www-api/app/Controllers/Home.php @@ -23,9 +23,11 @@ class Home extends BaseController try { // Send a ping to confirm a successful connection $client->selectDatabase('admin')->command(['ping' => 1]); - echo "Pinged your deployment. You successfully connected to MongoDB!\n"; + //echo "Pinged your deployment. You successfully connected to MongoDB!\n"; + log_message('critical', "Pinged your deployment. You successfully connected to MongoDB!"); } catch (Exception $e) { - printf($e->getMessage()); + log_message('critical', "Pinged your deployment. You failed connected to MongoDB! :: ".$e->getMessage()); + // printf($e->getMessage()); } //$client->createDBRef()