? 171034_comment_notify_if_checked_require_email.patch
? 192325_comment_notify_permission_to_use.patch
? 232564_comment_notify_refactor_for_own_table_and_postgres.patch
? 232564_comment_notify_refactor_for_own_table_and_postgres_4.patch
? 264584_comment_notify_limit_node_types.patch
? 282201_comment_notify_one_mail_per_comment.patch
? cvs-release-notes.php
Index: comment_notify.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/comment_notify/comment_notify.module,v
retrieving revision 1.1.4.12
diff -u -p -r1.1.4.12 comment_notify.module
--- comment_notify.module	17 Jul 2008 20:41:42 -0000	1.1.4.12
+++ comment_notify.module	23 Jul 2008 23:02:54 -0000
@@ -56,6 +56,13 @@ function comment_notify_form_alter($form
     return;
   }
 
+  // Only add the checkbox if this is an enabled content type
+  $node = node_load($form['nid']['#value']);
+  $enabled_types = variable_get('comment_notify_node_types', array());
+  if (!$enabled_types[$node->type]) {
+    return;
+  }  
+
   $op = isset($_POST['op']) ? $_POST['op'] : '';
 
   if ($op == t('Preview comment')) {
@@ -390,6 +397,21 @@ function comment_notify_unsubscribe_subm
 
 function comment_notify_settings() {
   $form['comment_notify_settings'] = array();
+
+  // Only perform comment_notify for certain node types (default, all)
+  foreach (node_get_types('names') as $type => $name) {
+    $checkboxes[$type] = check_plain($name);
+    $default[] = $type;
+  }
+
+  $form['comment_notify_settings']['comment_notify_node_types'] = array(
+    '#type' => 'checkboxes',
+    '#title' => t('Content Types To Enable for Comment Notify'),
+    '#default_value' => variable_get('comment_notify_node_types', $default),
+    '#options' => $checkboxes,
+    '#description' => t('Comments on content types enabled here will have the option of comment notification.'),
+  );
+
   $form['comment_notify_settings']['comment_notify_regged_checkbox'] = array(
     '#type' => 'checkbox',
     '#title' => t('Let registered users select notification on a node basis'),
