diff --git a/flag.flag.inc b/flag.flag.inc index 764a218..254b593 100644 --- a/flag.flag.inc +++ b/flag.flag.inc @@ -22,11 +22,6 @@ function flag_flag_type_info() { 'description' => t("Nodes are a Drupal site's primary content."), 'handler' => 'flag_node', ), - 'comment' => array( - 'title' => t('Comments'), - 'description' => t('Comments are responses to node content.'), - 'handler' => 'flag_comment', - ), 'user' => array( 'title' => t('Users'), 'description' => t('Users who have created accounts on your site.'), @@ -34,6 +29,14 @@ function flag_flag_type_info() { ), ); + if (module_exists('comment')) { + $definitions['comment'] = array( + 'title' => t('Comments'), + 'description' => t('Comments are responses to node content.'), + 'handler' => 'flag_comment', + ); + } + return $definitions; }