[Rt-commit] rt branch, 4.0/dryrun-comment, created. rt-4.0.1-121-gda488bb

Alex Vandiver alexmv at bestpractical.com
Tue Jul 19 13:42:31 EDT 2011


The branch, 4.0/dryrun-comment has been created
        at  da488bb4e161632c3e6d750dbf9c2465b367c255 (commit)

- Log -----------------------------------------------------------------
commit da488bb4e161632c3e6d750dbf9c2465b367c255
Author: Alex Vandiver <alexmv at bestpractical.com>
Date:   Tue Jul 19 13:42:11 2011 -0400

    Properly match on either UpdateType or Action
    
    Previously, having UpdateType set simply caused it to assume
    correspondence, due to precedence.  This was visible as the second time
    a Ticket Update page was loaded (due to GPG failure, "Add More Files",
    or whatnot), the Preview Scrips pane would act as if the transaction
    were a correspondence.  Fix this by properly adding parens to the regex
    target, which was improperly refactored in 25792acd.

diff --git a/lib/RT/Ticket.pm b/lib/RT/Ticket.pm
index cd6b8fe..d47cf13 100644
--- a/lib/RT/Ticket.pm
+++ b/lib/RT/Ticket.pm
@@ -2263,7 +2263,7 @@ sub DryRun {
     my $self = shift;
     my %args = @_;
     my $action;
-    if ($args{'UpdateType'} || $args{Action} =~ /^respon(d|se)$/i ) {
+    if (($args{'UpdateType'} || $args{Action}) =~ /^respon(d|se)$/i ) {
         $action = 'Correspond';
     } else {
         $action = 'Comment';

-----------------------------------------------------------------------


More information about the Rt-commit mailing list