voip_prepaid::lowBalance fix, take 2.

This commit is contained in:
abacab 2008-12-30 07:39:04 -05:00
parent d295494489
commit b33a038019

View File

@ -31,6 +31,12 @@ class voip_prepaid
{
# e-mail user's once when balance reaches this amount:
$this->lowBalance = $rs->fields[0];
}
else
{
$this->lowBalance = false;
}
$this->pinLenth = 10; // up to 10
# name of this module:
@ -51,7 +57,6 @@ class voip_prepaid
$this->order_by = $construct["construct"]["order_by"];
$this->limit = $construct["construct"]["limit"];
}
}
/** generate a new pin */
function genPin()
@ -78,7 +83,7 @@ class voip_prepaid
{
include_once(PATH_MODULES.'email_template/email_template.inc.php');
if ($this->lowBalance)
if (defined $this->lowBalance)
{
// delete expired pins?
// $delrs = & $db->Execute(sqlDelete($db,"voip_prepaid"," date_expire <> 0 and date_expire is not null and date_expire > ".time()));