check array to avoid errors

This commit is contained in:
Ian 2015-07-07 09:36:46 +02:00
parent 2e63945f60
commit 755fe60075

View File

@ -191,11 +191,13 @@ class Serendipity_Import_Serendipity extends Serendipity_Import {
}
}
if (is_array($this->storage[$table]) && !empty($this->storage[$table])) {
foreach($this->storage[$table] AS $primary_key => $primary_data) {
foreach($primary_data AS $primary_val => $replace_val) {
serendipity_set_config_var('import_s9y_' . $table . '_' . $primary_key . '_' . $primary_val, $replace_val, 99);
}
}
}
} else {
if ($this->debug && !$this->execute) {
echo "<span class='block_level'>Ignoring Duplicate.</span>";