[Rt-commit] r5704 - in rt/branches/3.7-EXPERIMENTAL: .
ruz at bestpractical.com
ruz at bestpractical.com
Sun Aug 6 23:02:32 EDT 2006
Author: ruz
Date: Sun Aug 6 23:02:31 2006
New Revision: 5704
Modified:
rt/branches/3.7-EXPERIMENTAL/ (props changed)
rt/branches/3.7-EXPERIMENTAL/lib/RT/Shredder/Plugin/Tickets.pm
Log:
r3600 at cubic-pc: cubic | 2006-08-07 07:04:39 +0400
Shredder::Plugin::Tickets
* make a case insensetive comparision of statuses
Modified: rt/branches/3.7-EXPERIMENTAL/lib/RT/Shredder/Plugin/Tickets.pm
==============================================================================
--- rt/branches/3.7-EXPERIMENTAL/lib/RT/Shredder/Plugin/Tickets.pm (original)
+++ rt/branches/3.7-EXPERIMENTAL/lib/RT/Shredder/Plugin/Tickets.pm Sun Aug 6 23:02:31 2006
@@ -42,10 +42,8 @@
if( $args{'status'} ) {
$queue ||= RT::Queue->new( $RT::SystemUser );
my @statuses = qw(new open stalled deleted rejected);
- if( $queue->can( 'StatusArray' ) ) {
- @statuses = $queue->StatusArray;
- }
- unless( grep $_ eq $args{'status'}, @statuses ) {
+ @statuses = $queue->StatusArray if $queue->can('StatusArray');
+ unless( grep lc $_ eq lc $args{'status'}, @statuses ) {
return( 0, "Invalid status '$args{status}'" );
}
}
More information about the Rt-commit
mailing list