Match better what is typical in the ticket subject

This commit is contained in:
Bradley M. Kuhn 2018-07-22 18:05:23 -07:00
parent 5c28767692
commit 421dd769cb

View file

@ -101,7 +101,7 @@ sub FindReimbursementTicketFromList(@) {
foreach my $ticket (@_) {
$ticket =~ s%\s*ticket/?\s*(\d+)\s*%$1%;
open(my $rtReimburseFH, "-|", "$RT_CMD", "ls", "-i", 'Queue = accounts-payable AND ' .
"Subject LIKE 'reimbursement' and Subject LIKE 'travel' and id = " . $ticket);
"(Subject LIKE 'reimbursement' OR Subject LIKE 'travel') and id = " . $ticket);
while (my $reimburseLine = <$rtReimburseFH>) {
if ($reimburseLine =~ m%\s*ticket\s*/?\s*(\d+)\s*$%) {
my $tt = $1;