cmd: "cvs" -z6 -f diff "node_age.module"
Index: node_age.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/spam/filters/node_age/Attic/node_age.module,v
retrieving revision 1.1.2.4.2.2
diff -r1.1.2.4.2.2 node_age.module
63,72c63,79
<   $action = array();
<   $id = spam_invoke_module($type, 'content_id', $content, $extra);
<   if (arg(0) == 'comment' && arg(1) == 'reply' && is_numeric(arg(2))) {
<     $nid = arg(2);
<     spam_log(SPAM_DEBUG, 'node_age_spam_filter', t('retrieved nid (@nid) from url', array('@nid' => $nid)), $type, $id);
<   }
<   else {
<     $nid = db_result(db_query('SELECT nid FROM {comments} WHERE cid = %d', $id));
<     spam_log(SPAM_DEBUG, 'node_age_spam_filter', t('retrieved nid (@nid) from database', array('@nid' => $nid)), $type, $id);
<   }
---
>   if ($type == 'comment') {
>     $action = array();
>     $id = spam_invoke_module($type, 'content_id', $content, $extra);
>     if (arg(0) == 'comment' && arg(1) == 'reply' && is_numeric(arg(2))) {
>       $nid = arg(2);
>       spam_log(SPAM_DEBUG, 'node_age_spam_filter', t('retrieved nid (@nid) from url', array('@nid' => $nid)), $type, $id);
>     }
>     else {
>       $nid = db_result(db_query('SELECT nid FROM {comments} WHERE cid = %d', $id));
>       spam_log(SPAM_DEBUG, 'node_age_spam_filter', t('retrieved nid (@nid) from database', array('@nid' => $nid)), $type, $id);
>     }
> 
>     if (!$nid) {
>       spam_log(SPAM_VERBOSE, 'node_age_spam_filter', t('warning: nid not found for comment (@cid), skipping', array('@cid' => $id)), $type, $id);
>       $action['total'] = 0;
>       return $action;
>     }
74d80
<   if ($type == 'comment' && $nid) {
89a96,98
>     } else {
>       spam_log(SPAM_VERBOSE, 'node_age_spam_filter', t('warning: nid (@nid) does not map to node, skipping', array('@nid' => $nid)), $type, $id);
>       $action['total'] = 0;

