[Koha-bugs] [Bug 14344] uninitialized value warning C4/Utils/DataTables/Members.pm
bugzilla-daemon at bugs.koha-community.org
bugzilla-daemon at bugs.koha-community.org
Fri Jun 5 18:48:12 CEST 2015
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14344
M. Tompsett <mtompset at hotmail.com> changed:
What |Removed |Added
----------------------------------------------------------------------------
Attachment #39911|0 |1
is obsolete| |
--- Comment #2 from M. Tompsett <mtompset at hotmail.com> ---
Created attachment 39914
-->
http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=39914&action=edit
Bug 14344: uninitialized value warning C4/Utils/DataTables/Members.pm
The condition for the assignment depends on $searchtype to be defined
and equal to 'contains'. So this change doesn't change the semantics.
- if $term !~ /^%/
- and $searchtype eq "contain";
+ if (defined $searchtype) && $searchtype eq "contain"
+ && $term !~ /^%/;
To test:
- Home -> Circulation -> Checkout
- Search for a user that does not exist (I searched 'whywouldthisexist') on the
intranet interface.
- Look at the intranet logs
=> FAIL: you get "Use of uninitialized value $searchtype in string eq at.,,"
- Apply the patch
- Repeat the search
=> SUCCESS: No warning
- Sign off :-D
NOTE: Other pages are more forgiving. Tweaked test plan.
Signed-off-by: Mark Tompsett <mtompset at hotmail.com>
--
You are receiving this mail because:
You are watching all bug changes.
More information about the Koha-bugs
mailing list