[otrs-cvs] otrs/Kernel/System/PostMaster/Filter MatchDBSource.pm, 1.21, 1.21.4.1

"CVS commits notifications of OTRS.org" <[email protected]>
Newsgroups gmane.comp.otrs.cvs
Message-ID <[email protected]>
Comments:
Update of /home/cvs/otrs/Kernel/System/PostMaster/Filter
In directory lancelot:/tmp/cvs-serv9753/Kernel/System/PostMaster/Filter

Modified Files:
      Tag: rel-3_1
	MatchDBSource.pm 
Log Message:
Fixed bug #9140 - Postmaster Filter for empty subjects does not work.

Author: ub

Index: MatchDBSource.pm
===================================================================
RCS file: /home/cvs/otrs/Kernel/System/PostMaster/Filter/MatchDBSource.pm,v
retrieving revision 1.21
retrieving revision 1.21.4.1
diff -2 -u -d -r1.21 -r1.21.4.1
--- MatchDBSource.pm	10 Dec 2010 15:35:52 -0000	1.21
+++ MatchDBSource.pm	7 Feb 2013 14:01:06 -0000	1.21.4.1
@@ -1,5 +1,5 @@
 # --
 # Kernel/System/PostMaster/Filter/MatchDBSource.pm - sub part of PostMaster.pm
-# Copyright (C) 2001-2010 OTRS AG, http://otrs.org/
+# Copyright (C) 2001-2013 OTRS AG, http://otrs.org/
 # --
 # $Id$
@@ -73,8 +73,8 @@
         my $Matched    = '';
         my $MatchedNot = 0;
-        for ( keys %Match ) {
+        for ( sort keys %Match ) {
 
             # match only email addresses
-            if ( $Param{GetParam}->{$_} && $Match{$_} =~ /^EMAILADDRESS:(.*)$/ ) {
+            if ( defined $Param{GetParam}->{$_} && $Match{$_} =~ /^EMAILADDRESS:(.*)$/ ) {
                 my $SearchEmail    = $1;
                 my @EmailAddresses = $Self->{ParserObject}->SplitAddressLine(
@@ -106,5 +106,5 @@
 
             # match string
-            elsif ( $Param{GetParam}->{$_} && $Param{GetParam}->{$_} =~ /$Match{$_}/i ) {
+            elsif ( defined $Param{GetParam}->{$_} && $Param{GetParam}->{$_} =~ /$Match{$_}/i ) {
 
                 # don't lose older match values if more than one header is
@@ -136,5 +136,5 @@
         # should I ignore the incoming mail?
         if ( $Matched && !$MatchedNot ) {
-            for ( keys %Set ) {
+            for ( sort keys %Set ) {
                 $Set{$_} =~ s/\[\*\*\*\]/$Matched/;
                 $Param{GetParam}->{$_} = $Set{$_};
---------------------------------------------------------------------
OTRS mailing list: cvs-log - Webpage: http://otrs.org/
Archive: http://lists.otrs.org/pipermail/cvs-log
To unsubscribe: http://lists.otrs.org/cgi-bin/listinfo/cvs-log
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.