Bugzilla – Attachment 65078 Details for
Bug 18942
CanUserUseBudget.t and CanUserModifyBudget.t missing system user test cases
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18942: Simplify syntax
Bug-18942-Simplify-syntax.patch (text/plain), 1.23 KB, created by
Jonathan Druart
on 2017-07-17 16:48:41 UTC
(
hide
)
Description:
Bug 18942: Simplify syntax
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2017-07-17 16:48:41 UTC
Size:
1.23 KB
patch
obsolete
>From 88729370b2be3b8d422ff5bec23981f14394d614 Mon Sep 17 00:00:00 2001 >From: Jonathan Druart <jonathan.druart@bugs.koha-community.org> >Date: Mon, 17 Jul 2017 13:48:17 -0300 >Subject: [PATCH] Bug 18942: Simplify syntax > >--- > C4/Budgets.pm | 14 ++++---------- > 1 file changed, 4 insertions(+), 10 deletions(-) > >diff --git a/C4/Budgets.pm b/C4/Budgets.pm >index 05f7ca5640..bcc84db83a 100644 >--- a/C4/Budgets.pm >+++ b/C4/Budgets.pm >@@ -917,11 +917,8 @@ sub CanUserUseBudget { > > if (not ref $borrower) { > $borrower = Koha::Patrons->find( $borrower ); >- if ( $borrower ) { >- $borrower = $borrower->unblessed; >- } else { >- return 0; >- } >+ return 0 unless $borrower; >+ $borrower = $borrower->unblessed; > } > if (not ref $budget) { > $budget = GetBudget($budget); >@@ -1005,11 +1002,8 @@ sub CanUserModifyBudget { > > if (not ref $borrower) { > $borrower = Koha::Patrons->find( $borrower ); >- if ( $borrower ) { >- $borrower = $borrower->unblessed; >- } else { >- return 0; >- } >+ return 0 unless $borrower; >+ $borrower = $borrower->unblessed; > } > if (not ref $budget) { > $budget = GetBudget($budget); >-- >2.11.0
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 18942
:
65051
|
65052
|
65055
|
65056
|
65078
|
65079
|
65080
|
65081
|
65082