Fix. Export valid values for settings in provision template. (#1685)

This commit is contained in:
Alexey Melnichuk 2016-06-20 20:40:22 +03:00 committed by FusionPBX
parent e058dd8c74
commit f6a923f5d7
2 changed files with 4 additions and 2 deletions

View File

@ -223,7 +223,7 @@ The file name is fixed to `Account1_Extern.xml`.
foreach($_SESSION['provision'] as $key=>$val) {
if (strlen($val['var']) > 0) { $value = $val['var']; }
if (strlen($val['text']) > 0) { $value = $val['text']; }
$provision[$key] = $value;
if (strlen($value) > 0) { $provision[$key] = $value; }
unset($value);
}

View File

@ -289,10 +289,12 @@ include "root.php";
}
//build the provision array
$provision = Array();
foreach($_SESSION['provision'] as $key=>$val) {
if (strlen($val['var']) > 0) { $value = $val['var']; }
if (strlen($val['text']) > 0) { $value = $val['text']; }
$provision[$key] = $value;
if (strlen($value) > 0) { $provision[$key] = $value; }
unset($value);
}
//check to see if the mac_address exists in devices