From 2f551b1755c4ea477c02e461a7a3556a3ebe7feb Mon Sep 17 00:00:00 2001 From: AGSTR <144728914+agstrxyz@users.noreply.github.com> Date: Tue, 7 May 2024 04:55:20 +0700 Subject: [PATCH] Update cron.php Fix Autorenewal radius plan base --- system/cron.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/system/cron.php b/system/cron.php index 4d03201b..5038aa7e 100644 --- a/system/cron.php +++ b/system/cron.php @@ -67,7 +67,7 @@ foreach ($d as $ds) { } } if ($p && $p['enabled'] && $c['balance'] >= $p['price']) { - if (Package::rechargeUser($ds['customer_id'], $p['routers'], $p['id'], 'Customer', 'Balance')) { + if (Package::rechargeUser($ds['customer_id'], $ds['routers'], $p['id'], 'Customer', 'Balance')) { // if success, then get the balance Balance::min($ds['customer_id'], $p['price']); echo "plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n"; @@ -127,7 +127,7 @@ foreach ($d as $ds) { } } if ($p && $p['enabled'] && $c['balance'] >= $p['price']) { - if (Package::rechargeUser($ds['customer_id'], $p['routers'], $p['id'], 'Customer', 'Balance')) { + if (Package::rechargeUser($ds['customer_id'], $ds['routers'], $p['id'], 'Customer', 'Balance')) { // if success, then get the balance Balance::min($ds['customer_id'], $p['price']); echo "plan enabled: $p[enabled] | User balance: $c[balance] | price $p[price]\n"; @@ -144,4 +144,4 @@ foreach ($d as $ds) { } else echo " : ACTIVE \r\n"; } -} \ No newline at end of file +}