summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorColan Schwartz2013-12-12 19:35:16 (GMT)
committerColan Schwartz2013-12-12 19:35:16 (GMT)
commit6bb3481afcd857e5944c80658e8f2a2bbf49e6fb (patch)
tree43e0e0763236041ff107cdf0413c90c2a8ff8ea2
parent899e2a093fe2fbbd66b46f6f098b6956ab8c8afa (diff)
Issue #1887996 by jenlampton, colan: Check for key before using it.
-rw-r--r--modules/content_migrate/modules/content_migrate.file.inc6
1 files changed, 4 insertions, 2 deletions
diff --git a/modules/content_migrate/modules/content_migrate.file.inc b/modules/content_migrate/modules/content_migrate.file.inc
index 4c72806..2e43cf1 100644
--- a/modules/content_migrate/modules/content_migrate.file.inc
+++ b/modules/content_migrate/modules/content_migrate.file.inc
@@ -32,8 +32,10 @@ function file_content_migrate_field_alter(&$field_value, $instance_value) {
$field_value['module'] = 'file';
$field_value['type'] = 'file';
// Some settings have changed names.
- $field_value['settings']['display_field'] = $field_value['settings']['list_field'];
- unset($field_value['settings']['list_field']);
+ if (array_key_exists('list_field', $field_value['settings'])) {
+ $field_value['settings']['display_field'] = $field_value['settings']['list_field'];
+ unset($field_value['settings']['list_field']);
+ }
$field_value['settings']['display_default'] = $field_value['settings']['list_default'];
unset($field_value['settings']['list_default']);
}