--- notify.module	2008-12-17 23:00:06.000000000 +0100
+++ notify.module	2010-03-07 21:42:52.000000000 +0100
@@ -69,6 +69,20 @@ function notify_admin_settings() {
     '#options' => array(t('Disabled'), 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 15, 20),
   );
     
+  $form['notify_settings']['notify_register_display'] = array(
+	'#type' => 'checkbox',
+	'#title' => 'Display Notification settings on the user registration form.',
+	'#return_value' => 1,
+	'#default_value' => variable_get('notify_register_display', 1),
+  );
+    
+  $form['notify_settings']['notify_register_default'] = array(
+	'#type' => 'checkbox',
+	'#title' => 'Enable notification by default for new user.',
+	'#return_value' => 1,
+	'#default_value' => variable_get('notify_register_default', 1),
+  );
+    
   $set = 'ntype';
   $form[$set] = array(
     '#type' => 'fieldset',
@@ -116,10 +130,13 @@ function notify_user($type, &$edit, &$us
       break;
     
     case 'register':
-      return _notify_user_reg_fields();
+      return variable_get('notify_register_display', 1) ? _notify_user_reg_fields() : NULL;
       break;
     
     case 'insert':
+      if(!variable_get('notify_register_display', 1)) {
+        $edit['notify_decision'] = variable_get('notify_register_default', 1);
+      }
       if (isset($edit['notify_decision']) && $edit['notify_decision'] == 1){
         db_query('INSERT INTO {notify} (uid, status, node, teasers, comment) VALUES (%d, %d, %d, %d, %d)', $user->uid, 1, 1, 0, 0);
         $edit['notify_decision'] = NULL;
@@ -149,7 +166,7 @@ function _notify_user_reg_fields() {
     '#type' => 'checkbox',
     '#title' => t('Receive email notifications of news posted to this site. Notifications are sent every ' . format_interval($period).'.'),
     '#return_value' => 1,
-    '#default_value' => 1,
+    '#default_value' => variable_get('notify_register_default', 1),
     '#description' => t('By accepting to receive <em>daily email news notifications</em>, you will be kept informed of news associated with ' . variable_get('site_name', 'Drupal') . '.')
   );
