Commit e2deccc8 authored by serge.aumont's avatar serge.aumont
Browse files

Now message for moderation is not attached in the message sent to the moderator if tagued as spam.




git-svn-id: https://subversion.renater.fr/sympa/trunk@4888 05aa8bb8-cd2b-0410-b1d7-8918dfa770ce
parent bdeb5897
From: [% fromlist %]
To: [% list.name %]-editor@[% list.host %]
[% IF request_topic -%]Subject: [% FILTER qencode %][%|loc(list.name,msg_from)%]Article to be tagged for list %1 from %2[%END%][%END%]
[% ELSE -%]Subject: [% FILTER qencode %][%|loc(list.name,msg_from)%]Article to be approved for list %1 from %2[%END%][%END%]
[% ELSE -%]Subject: [% FILTER qencode %][%|loc(list.name,msg_from)%]Message for list %1 from %2 to be approved[%END%][%END%]
[% END -%]
Reply-To: [% conf.email %]@[% conf.host %]
[% IF spam_status != 'spam' -%]
Content-Type: multipart/mixed; boundary="[% boundary %]"
--[% boundary %]
[% END -%]
Content-Type: text/plain; charset="UTF-8";
Content-Transfer-Encoding: 8bit
[%|loc(mod_spool_size,list.name)%]they are %1 messages awaiting moderation for list %2.[%END%]
[%|loc(conf.wwsympa_url,one_time_ticket) %]You can browse and accept or refuse them by web : %1/ticket/%2[% END %]
[%|loc(list.name,msg_from)%]One new message from list %1 from %2 arrived. [%END%]
[%- IF spam_status == 'spam' -%][%|loc%]This message as been tagued as a spam[%END%][% END %]
[%|loc(mod_spool_size)%]They are %1 messages awaiting moderation.[%END%]
[%|loc(conf.wwsympa_url,one_time_ticket) %]You can browse and accept or refuse them by web : %1/ticket/%2[%END%]
[% IF method == 'md5' -%]
[% IF request_topic -%][%|loc(list.name,conf.wwsympa_url,modkey)%]To tag the attached message in list %1 go to the following page :
[% IF request_topic -%][%|loc(list.name,conf.wwsympa_url,modkey)%]To tag the message in list %1 for the appropriate topic, please use the following link :
%2/viewmod/%1/%3
[%END%]
[%- ELSE -%]
[%- IF spam_status == 'spam' -%]
Because the new message is suspected to be a spam it is not attached to this one. You must use
the web interface to reject or validate it.
[%- ELSE -%]
[%|loc(list.name)%]To distribute the attached message in list %1:[%END%]
[% FILTER escape_url %]mailto:[%conf.sympa%]?subject=DISTRIBUTE [%list.name%] [%modkey%][% END %]
[%|loc(conf.email,conf.host)%]Or send a message to %1@%2 with the following subject :[%END%]
......@@ -28,8 +37,6 @@ DISTRIBUTE [% list.name %] [% modkey %]
[% FILTER escape_url %]mailto:[%conf.sympa%]?subject=REJECT [%list.name%] [%modkey%][% END %]
[%|loc(conf.email,conf.host)%]Or send a message to %1@%2 with the following subject :[%END%]
REJECT [% list.name %] [% modkey %]
[% END %]
[%- END -%]
--[% boundary %]
......@@ -41,3 +48,7 @@ X-Sympa-Attach: yes
[% INSERT $msg_path IF msg_path %]
--[% boundary %]--
[%- END -%]
[% END %]
[% END %]
......@@ -3471,18 +3471,17 @@ sub send_to_editor {
}
@rcpt = $self->get_editors_email();
my $hdr = $message->{'msg'}->head;
## Did we find a recipient?
if ($#rcpt < 0) {
&do_log('notice', "No editor found for list %s. Trying to proceed ignoring nomail option", $self->{'name'});
my $hdr = $message->{'msg'}->head;
my $messageid = $hdr->get('Message-Id');
@rcpt = $self->get_editors_email({'ignore_nomail',1});
&do_log('notice', 'Warning : no owner and editor defined at all in list %s', $name ) unless (@rcpt);
&do_log('notice', 'Warning : no owner and editor defined at all in list %s', $name )
unless (@rcpt);
## Could we find a recipient by ignoring the "nomail" option?
if ($#rcpt >= 0) {
&do_log('notice', 'All the intended recipients of message %s in list %s have set the "nomail" option. Ignoring it and sending it to all of them.', $messageid, $self->{'name'} );
......@@ -3496,6 +3495,8 @@ sub send_to_editor {
my $param = {'modkey' => $modkey,
'boundary' => $boundary,
'msg_from' => $message->{'sender'},
'subject' => $hdr->{'subject'},
'spam_status' => $message->{'spam_status'},
'mod_spool_size' => $self->get_mod_spool_size(),
'method' => $method};
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment