From 918631d676fbf09113142affdbe536bf6482fdba Mon Sep 17 00:00:00 2001 From: Duncan Sommerville Date: Thu, 5 Mar 2015 12:24:02 -0500 Subject: [PATCH] When calling /change, don't set prefs if empty/no parameters are given --- airtime_mvc/application/common/ProvisioningHelper.php | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/airtime_mvc/application/common/ProvisioningHelper.php b/airtime_mvc/application/common/ProvisioningHelper.php index 61127463a..f8e90b11c 100644 --- a/airtime_mvc/application/common/ProvisioningHelper.php +++ b/airtime_mvc/application/common/ProvisioningHelper.php @@ -219,8 +219,12 @@ class ProvisioningHelper * Initialize preference values passed from the dashboard (if any exist) */ private function initializePrefs() { - Application_Model_Preference::SetStationName($this->station_name); - Application_Model_Preference::SetStationDescription($this->description); + if ($this->statio_name) { + Application_Model_Preference::SetStationName($this->station_name); + } + if ($this->descption) { + Application_Model_Preference::SetStationDescription($this->description); + } } }