From 8e84c326163fcd3abba43b37409fa73feee5e6fb Mon Sep 17 00:00:00 2001 From: Ibnu Maksum Date: Tue, 21 Nov 2023 13:47:10 +0700 Subject: [PATCH] fix prepaid update --- system/boot.php | 2 +- system/controllers/prepaid.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/system/boot.php b/system/boot.php index 85eee719..4294c485 100644 --- a/system/boot.php +++ b/system/boot.php @@ -345,7 +345,7 @@ try { r2(U . 'dashboard', 'e', 'not found'); } } catch (Exception $e) { - if (isset($_SESSION['uid'])) { + if (!isset($_SESSION['aid']) || empty($_SESSION['aid'])) { r2(U . 'home' , 'e', $e->getMessage()); } $ui->assign("error_message", $e->getMessage() . '
' . $e->getTraceAsString() . '
'); diff --git a/system/controllers/prepaid.php b/system/controllers/prepaid.php index e4949b2a..f41b7259 100644 --- a/system/controllers/prepaid.php +++ b/system/controllers/prepaid.php @@ -219,7 +219,7 @@ switch ($action) { } else { $msg .= $_L['Data_Not_Found'] . '
'; } - $p = ORM::for_table('tbl_plans')->where('id', $plan_id)->where('enabled', '1')->find_one(); + $p = ORM::for_table('tbl_plans')->where('id', $id_plan)->where('enabled', '1')->find_one(); if ($d) { } else { $msg .= ' Plan Not Found
';