[Koha-patches] [PATCH] Fixes Bug 4232: Undefined hash references in Label Creator

Galen Charlton gmcharlt at gmail.com
Sat Feb 20 20:56:49 CET 2010


Hi Ian,

For some reason, your MUA or first MTA converted the patch into a
version with two attachments, an ASCII version of the patch and an
HTML version.  Furthermore, the text version cannot be applied without
manually editing it - not something I'm particularly willing to do
unless I'm resolving a merge conflict or handling a patch sent by a
newbie.

Please straighten out your MUA/MTA and resubmit or point me to a repo
I can pull or cherry-pick it from.   If need be, I can accept patches
as attachments.

Regards,

Galen

2010/2/19 Ian Walls <ian.walls at bywatersolutions.com>:
> Splits declaration and assignment of hashes into two lines to work more
> universally with different compilations of Perl.
>
> ---
>  C4/Creators/Lib.pm          |    3 ++-
>  labels/label-item-search.pl |    3 ++-
>  2 files changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/C4/Creators/Lib.pm b/C4/Creators/Lib.pm
> index 9b24833..3a2f421 100644
> --- a/C4/Creators/Lib.pm
> +++ b/C4/Creators/Lib.pm
> @@ -318,7 +318,8 @@ sub get_label_summary {
>             return -1;
>         }
>         my $record = $sth->fetchrow_hashref;
> -        my $label_summary->{'_label_number'} = $label_number;
> +        my $label_summary;
> +        $label_summary->{'_label_number'} = $label_number;
>         $record->{'author'} =~ s/[^\.|\w]$// if $record->{'author'};  #
> strip off ugly trailing chars... but not periods or word chars
>         $record->{'title'} =~ s/\W*$//;  # strip off ugly trailing chars
>         # FIXME contructing staff interface URLs should be done *much*
> higher up the stack - for the most part, C4 module code
> diff --git a/labels/label-item-search.pl b/labels/label-item-search.pl
> index df7f6a5..f06f236 100755
> --- a/labels/label-item-search.pl
> +++ b/labels/label-item-search.pl
> @@ -126,7 +126,8 @@ if ($show_results) {
>             foreach my $item ( keys %$item_results ) {
>                 #DEBUG Notes: Build an array element 'item' of the correct
> bib (results) hash which contains item-specific data...
>                 if ($item_results->{$item}->{'biblionumber'} eq
> $results_set[$i]->{'biblionumber'}) {
> -                    my $item_data->{'_item_number'} =
> $item_results->{$item}->{'itemnumber'};
> +                    my $item_data;
> +                     $item_data->{'_item_number'} =
> $item_results->{$item}->{'itemnumber'};
>                     $item_data->{'_item_call_number'} =
> ($item_results->{$item}->{'itemcallnumber'} ?
> $item_results->{$item}->{'itemcallnumber'} : 'NA');
>                     $item_data->{'_date_accessioned'} =
> $item_results->{$item}->{'dateaccessioned'};
>                     $item_data->{'_barcode'} = (
> $item_results->{$item}->{'barcode'} ? $item_results->{$item}->{'barcode'} :
> 'NA');
> --
> 1.5.6.5
>
>
>
> _______________________________________________
> Koha-patches mailing list
> Koha-patches at lists.koha.org
> http://lists.koha.org/mailman/listinfo/koha-patches
>



-- 
Galen Charlton
gmcharlt at gmail.com



More information about the Koha-patches mailing list