commit 417aeca48d6362d3c58c89aa51347baf7dcdbaef Author: Lee Rowlands Date: Thu Jun 20 10:25:45 2013 +1000 Fix some uninstall woes diff --git a/core/modules/comment/comment.install b/core/modules/comment/comment.install index 3a7f7f4..0498ac0 100644 --- a/core/modules/comment/comment.install +++ b/core/modules/comment/comment.install @@ -12,7 +12,9 @@ */ function comment_uninstall() { // Delete comment_body field. - field_info_field('comment_body')->delete(); + if ($field = field_info_field('comment_body')) { + $field->delete(); + } // Remove variables. variable_del('comment_block_count'); diff --git a/core/modules/forum/forum.install b/core/modules/forum/forum.install index d779dee..070818e 100644 --- a/core/modules/forum/forum.install +++ b/core/modules/forum/forum.install @@ -133,7 +133,9 @@ function forum_uninstall() { // Delete comment field, load comment in case it has been disabled. drupal_load('module', 'comment'); // Remove the forum comment field. - field_info_field('comment_node_forum')->delete(); + if ($field = field_info_field('comment_node_forum')) { + $field->delete(); + } // Purge field data now to allow taxonomy and comment modules to be // uninstalled if these were the only fields remaining. We need to call