Bugzilla – Attachment 10241 Details for
Bug 5911
Transport Cost Matrix of transporting an item between branches
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
bug_5911: make perlcdritic happy, shut up warnings
bug5911-make-perlcdritic-happy-shut-up-warnings.patch (text/plain), 1.25 KB, created by
Srdjan Jankovic
on 2012-06-12 02:18:55 UTC
(
hide
)
Description:
bug_5911: make perlcdritic happy, shut up warnings
Filename:
MIME Type:
Creator:
Srdjan Jankovic
Created:
2012-06-12 02:18:55 UTC
Size:
1.25 KB
patch
obsolete
>From 3f201c5963bc93f1bcab381df20b9c922b6803d1 Mon Sep 17 00:00:00 2001 >From: Srdjan <srdjan@catalyst.net.nz> >Date: Tue, 12 Jun 2012 14:15:25 +1200 >Subject: [PATCH] bug_5911: make perlcdritic happy, shut up warnings > >--- > C4/HoldsQueue.pm | 10 +++++++++- > 1 file changed, 9 insertions(+), 1 deletion(-) > >diff --git a/C4/HoldsQueue.pm b/C4/HoldsQueue.pm >index fcb3c14..05095d8 100755 >--- a/C4/HoldsQueue.pm >+++ b/C4/HoldsQueue.pm >@@ -564,11 +564,18 @@ sub debug { > # warn @_; > } > >+sub _trim { >+ return $_[0] unless $_[0]; >+ $_[0] =~ s/^\s+//; >+ $_[0] =~ s/\s+$//; >+ $_[0]; >+} >+ > sub load_branches_to_pull_from { > my $static_branch_list = C4::Context->preference("StaticHoldsQueueWeight") > or return; > >- my @branches_to_use = map { s/^\s+//; s/\s+$//; $_; } split /,/, $static_branch_list; >+ my @branches_to_use = map _trim($_), split /,/, $static_branch_list; > > @branches_to_use = shuffle(@branches_to_use) if C4::Context->preference("RandomizeHoldsQueueWeight"); > >@@ -590,6 +597,7 @@ sub least_cost_branch { > next if $cell->{disable_transfer}; > > my $cost = $cell->{cost}; >+ next unless defined $cost; # XXX should this be reported? > > unless (defined $least_cost) { > $least_cost = $cost; >-- >1.7.9.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 5911
:
3559
|
4689
|
7799
|
9576
|
9600
|
9626
|
9752
|
9850
|
10241
|
10431
|
10733
|
10882
|
10919
|
11075
|
11095
|
11096
|
11140
|
11144
|
11777
|
11820
|
11971