From 24370964737bf8c71f081a8c9bb8234ef4a7e1b0 Mon Sep 17 00:00:00 2001 From: Ibnu Maksum Date: Thu, 29 Feb 2024 09:25:26 +0700 Subject: [PATCH] $_c to $config in php file --- system/controllers/order.php | 4 ++-- system/controllers/settings.php | 4 ++-- system/cron.php | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/system/controllers/order.php b/system/controllers/order.php index 03003430..cee6b454 100644 --- a/system/controllers/order.php +++ b/system/controllers/order.php @@ -142,7 +142,7 @@ switch ($action) { $ui->display('user-orderView.tpl'); break; case 'pay': - if ($_c['enable_balance'] != 'yes') { + if ($config['enable_balance'] != 'yes') { r2(U . "order/package", 'e', Lang::T("Balance not enabled")); } $plan = ORM::for_table('tbl_plans')->where('enabled', '1')->find_one($routes['3']); @@ -176,7 +176,7 @@ switch ($action) { } break; case 'send': - if ($_c['enable_balance'] != 'yes') { + if ($config['enable_balance'] != 'yes') { r2(U . "order/package", 'e', Lang::T("Balance not enabled")); } $ui->assign('_title', Lang::T('Buy for friend')); diff --git a/system/controllers/settings.php b/system/controllers/settings.php index 13804c1e..a2f33fdd 100644 --- a/system/controllers/settings.php +++ b/system/controllers/settings.php @@ -36,9 +36,9 @@ switch ($action) { $logo = $UPLOAD_PATH . DIRECTORY_SEPARATOR . 'logo.default.png'; } $ui->assign('logo', $logo); - if ($_c['radius_enable'] && empty($_c['radius_client'])) { + if ($config['radius_enable'] && empty($config['radius_client'])) { try { - $_c['radius_client'] = Radius::getClient(); + $config['radius_client'] = Radius::getClient(); $ui->assign('_c', $_c); } catch (Exception $e) { //ignore diff --git a/system/cron.php b/system/cron.php index de95b87f..7616187c 100644 --- a/system/cron.php +++ b/system/cron.php @@ -24,7 +24,7 @@ echo "Found " . count($d) . " user(s)\n"; run_hook('cronjob'); #HOOK foreach ($d as $ds) { - if ($ds['type'] == 'Hotspot') { + if ($ds['type'] == 'Hotspot') { # HOTSPOT $date_now = strtotime(date("Y-m-d H:i:s")); $expiration = strtotime($ds['expiration'] . ' ' . $ds['time']); echo $ds['expiration'] . " : " . (($isCli) ? $ds['username'] : Lang::maskText($ds['username'])); @@ -82,7 +82,7 @@ foreach ($d as $ds) { } } else echo " : ACTIVE \r\n"; - } else { + } else { # PPPOE $date_now = strtotime(date("Y-m-d H:i:s")); $expiration = strtotime($ds['expiration'] . ' ' . $ds['time']); echo $ds['expiration'] . " : " . (($isCli) ? $ds['username'] : Lang::maskText($ds['username']));