supplimental patch for bug #204679

when running junk mail commands on the current folder
we need to "pass over" emails from people in the whitelist (if we are doing
whitelisting, for this account), instead of marking them as good.

thanks to bienvenu for catching my mistake.

r/sr=bienvenu, a=sspitzer


git-svn-id: svn://10.0.0.236/trunk@142518 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
sspitzer%netscape.com
2003-05-15 23:15:49 +00:00
parent 89d37d3b6c
commit c16ae372a1

View File

@@ -435,10 +435,13 @@ function analyze(aMsgHdr, aNextFunction)
var listener = {
onMessageClassified: function(aMsgURI, aClassification)
{
// XXX todo
// update status bar, or a progress dialog
// running junk mail controls manually, on a large folder
// can take a while, and the user doesn't know when we are done.
dump(aMsgURI + ' is '
+ (aClassification == nsIJunkMailPlugin.JUNK
? 'JUNK' : 'GOOD') + '\n');
// XXX TODO, make the cut off 50, like in nsMsgSearchTerm.cpp
var score =
aClassification == nsIJunkMailPlugin.JUNK ? "100" : "0";
@@ -464,7 +467,10 @@ function analyze(aMsgHdr, aNextFunction)
headerParser.extractHeaderAddressMailboxes(null, aMsgHdr.author, authorEmailAddress);
if (whiteListDirectory.hasCardForEmailAddress(authorEmailAddress.value))
{
listener.onMessageClassified(aMsgHdr.folder.generateMessageURI(aMsgHdr.messageKey), nsIJunkMailPlugin.GOOD);
// skip over this message, like we do on incoming mail
// the difference is it could be marked as junk from previous analysis
// or from being manually marked by the user.
aNextFunction();
return;
}
}