From 3f22f89654741f55cb4592dc2bdf5ac8f22b340a Mon Sep 17 00:00:00 2001 From: dongpd Date: Tue, 19 Jan 2021 15:47:47 +0700 Subject: [PATCH] try catch reset device --- controllers/ConfigController.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/controllers/ConfigController.php b/controllers/ConfigController.php index 50f4836a..c5cf632d 100644 --- a/controllers/ConfigController.php +++ b/controllers/ConfigController.php @@ -336,7 +336,11 @@ class ConfigController extends Controller { \Yii::$app->db->createCommand()->truncateTable('capture_logs')->execute(); \Yii::$app->db->createCommand()->truncateTable('list_management')->execute(); array_map('unlink', glob("/var/www/html/BiFace_Server_Lite/web/data/uploads/face/*.*")); - file_get_contents("http://localhost:2305/update-feature"); + try { + file_get_contents("http://localhost:2305/update-feature"); + } catch (Exception $exc) { + echo $exc->getTraceAsString(); + } } return Url::to(['/config']); } else {