Commit e0975510 authored by good_man's avatar good_man

Issue #1135466: Renaming a content type results in notices

parent 132008f6
......@@ -529,8 +529,10 @@ function content_access_node_type_update($info) {
if (!empty($info->old_type) && $info->old_type != $info->type) {
$settings = content_access_get_settings();
foreach (content_access_available_settings() as $setting) {
$settings[$setting][$info->type] = $settings[$setting][$info->old_type];
unset($settings[$setting][$info->old_type]);
if (isset($settings[$setting][$info->old_type])) {
$settings[$setting][$info->type] = $settings[$setting][$info->old_type];
unset($settings[$setting][$info->old_type]);
}
}
content_access_set_settings($settings);
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment