// no old data found $arrReturn[$strSection] = array('type' => 'error missing-option', 'message' => sprintf('Import for %s failed, because the related option (%s) is empty or does not exist', $strSection, $arrOptionData[$strSection]['old_option_name'])); } } } } else { parent::debug('arrImportOptions are empty!'); } if (!empty($arrReturn)) { $return = $arrReturn; } return $return; } } // return if (updateHelper::is_correct_version('2.0', '2.1') == false) { $arrResult = array('type' => 'error wrong-version', 'message' => 'Wrong update script version.'); //echo 'does not compute'; //break; return; } // include update data require_once get_template_directory() . '/includes/admin/updates/cc20-update-data.php'; // test if there actually ARE old settings $has_old_settings = updateHelper::has_importable_settings($arrOptions); if ($has_old_settings == false) { $arrResult = array('type' => 'error no-old-settings', 'message' => 'No old settings for import found.'); $exec_update = false; } // abort if specific $run_update variable is not set if (!isset($exec_update) || $exec_update != true) {