[Rt-commit] r15793 - rt/3.8/trunk/lib/RT/Interface

sunnavy at bestpractical.com sunnavy at bestpractical.com
Mon Sep 8 04:01:36 EDT 2008


Author: sunnavy
Date: Mon Sep  8 04:01:35 2008
New Revision: 15793

Modified:
   rt/3.8/trunk/lib/RT/Interface/Web.pm

Log:
trivial regex fix

Modified: rt/3.8/trunk/lib/RT/Interface/Web.pm
==============================================================================
--- rt/3.8/trunk/lib/RT/Interface/Web.pm	(original)
+++ rt/3.8/trunk/lib/RT/Interface/Web.pm	Mon Sep  8 04:01:35 2008
@@ -256,7 +256,8 @@
 
     # Find the signature
     my $sig = $args{'CurrentUser'}->UserObj->Signature || '';
-    $sig =~ s/^\s*|\s*$//g;
+    $sig =~ s/^\s+//;
+    $sig =~ s/\s+$//;
 
     # Check for plaintext sig
     return '' if not $html and $content =~ /^\s*(--)?\s*\Q$sig\E\s*$/;
@@ -1453,7 +1454,7 @@
 
             for my $luri ( split ( / /, $ARGSRef->{ $Record->Id . "-$linktype" } ) ) {
                 next unless $luri;
-                $luri =~ s/\s*$//;    # Strip trailing whitespace
+                $luri =~ s/\s+$//;    # Strip trailing whitespace
                 my ( $val, $msg ) = $Record->AddLink( Target => $luri,
                                                       Type   => $linktype );
                 push @results, $msg;


More information about the Rt-commit mailing list