Index: openacs-4/packages/acs-mail-lite/www/doc/incoming-email-legacy-notes.adp =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/acs-mail-lite/www/doc/incoming-email-legacy-notes.adp,v diff -u -r1.4.2.1 -r1.4.2.2 --- openacs-4/packages/acs-mail-lite/www/doc/incoming-email-legacy-notes.adp 19 Jul 2019 08:50:14 -0000 1.4.2.1 +++ openacs-4/packages/acs-mail-lite/www/doc/incoming-email-legacy-notes.adp 19 Jul 2019 09:00:32 -0000 1.4.2.2 @@ -362,33 +362,33 @@ set to [acs_mail_lite::parse_email_address -email $email(to)] ns_log Debug "acs_mail_lite::incoming_email -impl acs-mail-lite called. Recipient $to" - util_unlist [acs_mail_lite::parse_bounce_address -bounce_address $to] user_id package_id signature + lassign [acs_mail_lite::parse_bounce_address -bounce_address $to] user_id package_id signature # If no user_id found or signature invalid, ignore message # Here we decide not to deal with the message anymore - if {[empty_string_p $user_id]} { - if {[empty_string_p $user_id]} { - ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: No equivalent user found for $to" + if {$user_id eq ""} { + #if {$user_id eq ""} { + ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: No equivalent user found for $to" + #} else { + #ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: Invalid mail signature $signature" + #} } else { - ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: Invalid mail signature $signature" + ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: Bounce checking $to, $user_id" + + if { ![acs_mail_lite::bouncing_user_p -user_id $user_id] } { + ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: Bouncing email from user $user_id" + # record the bounce in the database + db_dml record_bounce {} + + if {![db_resultrows]} { + db_dml insert_bounce {} + } + } } - } else { - ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: Bounce checking $to, $user_id" - - if { ![acs_mail_lite::bouncing_user_p -user_id $user_id] } { - ns_log Debug "acs_mail_lite::incoming_email impl acs-mail-lite: Bouncing email from user $user_id" - # record the bounce in the database - db_dml record_bounce {} - - if {![db_resultrows]} { - db_dml insert_bounce {} } - } - } - }