diff --git a/app/provision/index.php b/app/provision/index.php index f7d8d62e50..993e1865d5 100644 --- a/app/provision/index.php +++ b/app/provision/index.php @@ -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); } diff --git a/app/provision/resources/classes/provision.php b/app/provision/resources/classes/provision.php index 8f57c0bb52..6ae40c38e2 100644 --- a/app/provision/resources/classes/provision.php +++ b/app/provision/resources/classes/provision.php @@ -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