The difference here is the number of arguments to join.  Paul's syntax is
correct if "\n" is supposed to be an argument to join, but it seems in this
case it is not.  The original intent could be clarified with parens:

> -   $titles .= join "\t", @item_info . "\n";
> +  $titles .= join "\t", @item_info , "\n";

becoming:

> -   $titles .= join("\t", @item_info) . "\n";
> +  $titles .= join("\t", @item_info , "\n");


On Tue, Aug 5, 2008 at 4:02 PM, Galen Charlton
<[EMAIL PROTECTED]>wrote:

> Hi Paul,
>
> If you don't mind, I've just submitted a variant of your patch under
> bug 2473 - the problem with yours is that it adds an extra "\t"
> between the last field and the newline.
>
> Regards,
>
> Galen
>
> On Tue, Aug 5, 2008 at 11:53 AM,  <[EMAIL PROTECTED]> wrote:
> > From: Paul POULAIN <[EMAIL PROTECTED]>
> >
> > The proper syntax is with a ,
> > ---
> >  misc/cronjobs/overdue_notices.pl |    2 +-
> >  1 files changed, 1 insertions(+), 1 deletions(-)
> >
> > diff --git a/misc/cronjobs/overdue_notices.pl
> b/misc/cronjobs/overdue_notices.pl
> > index ced4e64..4901cec 100755
> > --- a/misc/cronjobs/overdue_notices.pl
> > +++ b/misc/cronjobs/overdue_notices.pl
> > @@ -363,7 +363,7 @@ END_SQL
> >                 my $titles = "";
> >                 while ( my $item_info = $sth2->fetchrow_hashref() ) {
> >                     my @item_info = map { $_ =~ /date$/ ? format_date(
> $item_info->{$_} ) : $item_info->{$_} || '' } @item_content_fields;
> > -                    $titles .= join "\t", @item_info . "\n";
> > +                    $titles .= join "\t", @item_info , "\n";
> >                 }
> >                 $sth2->finish;
>
> --
> Galen Charlton
> VP, Research & Development, LibLime
> [EMAIL PROTECTED]
> p: 1-888-564-2457 x709
> skype: gmcharlt
>
_______________________________________________
Koha-patches mailing list
[email protected]
http://lists.koha.org/mailman/listinfo/koha-patches

Reply via email to