[PATCH] changed spamassassin plugin note to plugin name

[email protected] (Matt Simerson)
Newsgroups perl.qpsmtpd
Message-ID <[email protected]>
per Robert's comments.


---
plugins/dspam        |    6 +++---
plugins/spamassassin |    2 +-
2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/plugins/dspam b/plugins/dspam
index d6ef1ce..6f6c19a 100644
--- a/plugins/dspam
+++ b/plugins/dspam
@@ -320,8 +320,8 @@ sub get_dspam_results {
sub get_spamassassin_results {
    my ($self, $transaction) = @_;

-    if ( $transaction->notes('spamass' ) ) {
-        return split(':', $transaction->notes('spamass' ) );
+    if ( $transaction->notes('spamassassin' ) ) {
+        return split(':', $transaction->notes('spamassassin' ) );
    };

    my $sa_status = $transaction->header->get('X-Spam-Status') or do {
@@ -335,7 +335,7 @@ sub get_spamassassin_results {

    $self->log(LOGINFO, "SA: $is_spam; $score; $autolearn");

-    $transaction->notes('spamass', "$is_spam:$score:$autolearn");
+    $transaction->notes('spamassassin', "$is_spam:$score:$autolearn");

    return ($is_spam, $score, $autolearn);
};
diff --git a/plugins/spamassassin b/plugins/spamassassin
index 534d712..b69599c 100644
--- a/plugins/spamassassin
+++ b/plugins/spamassassin
@@ -250,7 +250,7 @@ sub insert_spam_headers {
            my ( $is_spam,undef,$score,$autolearn ) = $new_headers->{$name}
                =~ /^(yes|no), (score|hits)=([\d\.\-]+)\s.*?autolearn=([\w]+)/i;
            $self->log(LOGINFO, "SA: $is_spam; $score; $autolearn");
-            $transaction->notes('spamass', "$is_spam:$score:$autolearn");
+            $transaction->notes('spamassassin', "$is_spam:$score:$autolearn");
        };
        $new_headers->{$name} =~ s/\015//; # hack for outlook (still necessary?)
        $self->_cleanup_spam_header($transaction, $name);
-- 
1.7.9.6
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.