Fix bug in my last commit
This commit is contained in:
parent
2594105a5e
commit
db596d54b5
|
@ -1593,18 +1593,18 @@ class Application_Model_Preference
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public static function getBandwidthLimit() {
|
public static function getBandwidthLimit() {
|
||||||
$val = self::getValue("bandwidth_limit");
|
$bandwidthLimit = self::getValue("bandwidth_limit");
|
||||||
if (empty($val)) {
|
if (empty($bandwidthLimit)) {
|
||||||
// Set and return the plan defaults
|
// Set and return the plan defaults
|
||||||
// TODO: remove this once all existing customers have this pref set
|
// TODO: remove this once all existing customers have this pref set
|
||||||
$planType = self::GetPlanLevel();
|
$planType = self::GetPlanLevel();
|
||||||
$val = "starter";
|
$bandwidthLimit = Billing::$PLAN_TYPE_DEFAULTS["starter"]["bandwidth_limit"];
|
||||||
if (isset(Billing::$PLAN_TYPE_DEFAULTS[$planType])) {
|
if (isset(Billing::$PLAN_TYPE_DEFAULTS[$planType])) {
|
||||||
$val = Billing::$PLAN_TYPE_DEFAULTS[$planType]["bandwidth_limit"];
|
$bandwidthLimit = Billing::$PLAN_TYPE_DEFAULTS[$planType]["bandwidth_limit"];
|
||||||
}
|
}
|
||||||
self::setBandwidthLimit($val);
|
self::setBandwidthLimit($bandwidthLimit);
|
||||||
}
|
}
|
||||||
return $val;
|
return $bandwidthLimit;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function setBandwidthLimit($value) {
|
public static function setBandwidthLimit($value) {
|
||||||
|
|
Loading…
Reference in New Issue