Skip to content

Commit

Permalink
make sure $att is defined before calling it
Browse files Browse the repository at this point in the history
forward txns before RT 4.2 don't have any attachments, we need to get around
it with more conservative code.  (thanks cloos++)
  • Loading branch information
sunnavy committed Apr 27, 2015
1 parent 605a5fc commit 5c774cb
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions etc/upgrade/4.2.11/content
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ EOSQL
$txns->Limit( FIELD => 'Type', VALUE => 'Forward Ticket' );
while ( my $txn = $txns->Next ) {
my $att = $txn->Attachments->First;
next unless $att;

# we only need to process ascii-only strings
unless ( $att->Subject =~ /[^\x00-\x7F]/ ) {
Expand Down

0 comments on commit 5c774cb

Please sign in to comment.