mirror of
https://github.com/kevachat/webapp.git
synced 2025-02-02 01:44:27 +00:00
fix pool balance condition
This commit is contained in:
parent
3bc438a84b
commit
a45142f6d7
@ -61,10 +61,10 @@ class CrontabController extends AbstractController
|
|||||||
// Payment received, send to blockchain
|
// Payment received, send to blockchain
|
||||||
if ($client->getReceivedByAddress($pool->getAddress(), $this->getParameter('app.pool.confirmations')) >= $pool->getCost())
|
if ($client->getReceivedByAddress($pool->getAddress(), $this->getParameter('app.pool.confirmations')) >= $pool->getCost())
|
||||||
{
|
{
|
||||||
// Check physical wallet balance
|
// Check physical account balance
|
||||||
if ($client->getBalance($this->getParameter('app.kevacoin.pool.account')) <= $pool->getCost())
|
if ($client->getBalance($this->getParameter('app.kevacoin.pool.account'), $this->getParameter('app.pool.confirmations')) < $pool->getCost())
|
||||||
{
|
{
|
||||||
break; // @TODO exception
|
continue; // wait for income full confirmed amount
|
||||||
}
|
}
|
||||||
|
|
||||||
// Is room request
|
// Is room request
|
||||||
|
Loading…
x
Reference in New Issue
Block a user