From 482a87eaf9946d704c8d242afd56749633ded366 Mon Sep 17 00:00:00 2001 From: Joshua Ferraro Date: Fri, 8 Aug 2008 10:51:45 -0500 Subject: [PATCH] Revert "Add missing to and from email addresses to user and admin EnqueueLetter calls, respectively. Add extra level to verbosity." This reverts commit 67f229cba7395485a22fc0effa67ca4f592408f4. --- misc/cronjobs/overdue_notices.pl | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/misc/cronjobs/overdue_notices.pl b/misc/cronjobs/overdue_notices.pl index 532215dbfb..64e372214e 100755 --- a/misc/cronjobs/overdue_notices.pl +++ b/misc/cronjobs/overdue_notices.pl @@ -53,7 +53,6 @@ overdue_notices.pl [ -n ] [ -library ] [ -max ] [ -library only deal with overdues from this library -csv populate CSV file -itemscontent item information in templates - -v verbose ( use multiple times to increase verbosity ) =head1 OPTIONS @@ -219,7 +218,7 @@ my $itemscontent = join( ',', qw( issuedate title barcode author ) ); GetOptions( 'help|?' => \$help, 'man' => \$man, - 'v+' => \$verbose, + 'v' => \$verbose, 'n' => \$nomail, 'max=s' => \$MAX, 'library=s' => \$mybranch, @@ -228,6 +227,7 @@ GetOptions( ) or pod2usage(2); pod2usage(1) if $help; pod2usage( -verbose => 2 ) if $man; + if ( defined $csvfilename && $csvfilename =~ /^-/ ) { warn qq(using "$csvfilename" as filename, that seems odd); } @@ -339,10 +339,10 @@ END_SQL push @borrower_parameters, $mindays, $maxdays; my $sth = $dbh->prepare($borrower_sql); $sth->execute(@borrower_parameters); - ($verbose>1) and warn $borrower_sql . "\n\n ($mindays, $maxdays)\nreturns " . $sth->rows . " rows"; + $verbose and warn $borrower_sql . "\n\n ($mindays, $maxdays)\nreturns " . $sth->rows . " rows"; while ( my ( $itemcount, $borrowernumber, $firstname, $lastname, $address1, $address2, $city, $postcode, $email ) = $sth->fetchrow ) { - warn "borrower $firstname, $lastname ($borrowernumber) [ $email ] has $itemcount items overdue." if $verbose; + warn "borrower $firstname, $lastname ($borrowernumber) has $itemcount items overdue." if $verbose; my $letter = C4::Letters::getletter( 'circulation', $overdue_rules->{"letter$i"} ); unless ($letter) { @@ -409,7 +409,6 @@ END_SQL { letter => $letter, borrowernumber => $borrowernumber, message_transport_type => 'email', - to_address => $email, from_address => $admin_email_address, } ); @@ -465,7 +464,6 @@ END_SQL message_transport_type => 'email', attachments => [$attachment], to_address => $admin_email_address, - from_address => $admin_email_address, } ); } -- 2.39.5