mirror of
https://github.com/FOSSBilling/FOSSBilling.git
synced 2026-11-22 13:02:39 +09:00
Critical - Fix client balance deletion query
Fix critical issue where deleting client empties all funds records from database.
This commit is contained in:
1 parent
9904f0f520
commit
c767bb0c0d
1 file changed
+1
-1
@@ -54,7 +54,7 @@ class ServiceBalance implements InjectionAwareInterface
|
||||
|
||||
public function rmByClient(\Model_Client $client)
|
||||
{
|
||||
$clientBalances = $this->di['db']->find('ClientBalance', 'client_id', array($client->id));
|
||||
$clientBalances = $this->di['db']->find('ClientBalance', 'client_id = ?', array($client->id));
|
||||
foreach ($clientBalances as $balanceModel){
|
||||
$this->di['db']->trash($balanceModel);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user