Check the missing array has content before processing it.

This commit is contained in:
markjcrane
2016-05-04 00:22:35 -06:00
parent 7aa61e2d53
commit 3abaff004c
10 changed files with 63 additions and 58 deletions
+2 -1
View File
@@ -137,6 +137,7 @@ if ($domains_processed == 1) {
$array[$x]['default_setting_enabled'] = 'true';
$array[$x]['default_setting_description'] = 'Delay before next call sequence';
$x++;
//get an array of the default settings
$sql = "select * from v_default_settings ";
$prep_statement = $db->prepare($sql);
@@ -160,7 +161,7 @@ if ($domains_processed == 1) {
}
//add the missing default settings
foreach ($missing as $row) {
if (count($missing) > 0) foreach ($missing as $row) {
//add the default settings
$orm = new orm;
$orm->name('default_settings');