[Bug 10291] New: Misleading Variable names in batchMod.pl
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Bug ID: 10291 Summary: Misleading Variable names in batchMod.pl Classification: Unclassified Change sponsored?: --- Product: Koha Version: master Hardware: All OS: All Status: NEW Severity: enhancement Priority: P5 - low Component: Architecture, internals, and plumbing Assignee: gmcharlt@gmail.com Reporter: colin.campbell@ptfs-europe.com batchMod,pl has two variables with names of the form x_hashref but both are actually references to an array of hashrefs. It passes the contents of one to the templares under the name itemnumbers_hashref but the use of it belies that name. For the sake of future maintainers lets clean up these names -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Colin Campbell <colin.campbell@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Assignee|gmcharlt@gmail.com |colin.campbell@ptfs-europe. | |com --- Comment #1 from Colin Campbell <colin.campbell@ptfs-europe.com> --- Created attachment 18259 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18259&action=edit proposed patch -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Srdjan Jankovic <srdjan@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |srdjan@catalyst.net.nz --- Comment #2 from Srdjan Jankovic <srdjan@catalyst.net.nz> --- It looks pointless to me to have hashrefs with only one key 'itemnumber'. Would you consider changing those arrays to be pure itemnumbers please, while you're at it? -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Colin Campbell <colin.campbell@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |ASSIGNED --- Comment #3 from Colin Campbell <colin.campbell@ptfs-europe.com> --- (In reply to comment #2)
It looks pointless to me to have hashrefs with only one key 'itemnumber'. Would you consider changing those arrays to be pure itemnumbers please, while you're at it?
Yes in fact that simplifies the patch. Will post an update -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Colin Campbell <colin.campbell@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18259|0 |1 is obsolete| | --- Comment #4 from Colin Campbell <colin.campbell@ptfs-europe.com> --- Created attachment 18629 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18629&action=edit Updated patch Simplified the patch by not processing an array to look like a hash just to save a variable name. Passes an array of itemnumbers as exactly that -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Colin Campbell <colin.campbell@ptfs-europe.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |Needs Signoff -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Srdjan Jankovic <srdjan@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18629|0 |1 is obsolete| | --- Comment #5 from Srdjan Jankovic <srdjan@catalyst.net.nz> --- Created attachment 18634 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=18634&action=edit [SIGNED-OFF] Bug 10291: Clarify misleading variable name Remove the unrequired extra processing and pass the array of itemnumbers as itemnumbers_array Signed-off-by: Srdjan <srdjan@catalyst.net.nz> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Srdjan Jankovic <srdjan@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA CC| |jonathan.druart@biblibre.co | |m Patch complexity|--- |Trivial patch QA Contact| |jonathan.druart@biblibre.co | |m --- Comment #6 from Jonathan Druart <jonathan.druart@biblibre.com> --- QA comment: Variable renaming. Need to modify the max amount of items (l. 113) and see the html code source for testing this patch. No regression, no change detected. Marked as Passed QA. -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Jonathan Druart <jonathan.druart@biblibre.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #18634|0 |1 is obsolete| | --- Comment #7 from Jonathan Druart <jonathan.druart@biblibre.com> --- Created attachment 19076 --> http://bugs.koha-community.org/bugzilla3/attachment.cgi?id=19076&action=edit Bug 10291: Clarify misleading variable name Remove the unrequired extra processing and pass the array of itemnumbers as itemnumbers_array Signed-off-by: Srdjan <srdjan@catalyst.net.nz> Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> -- You are receiving this mail because: You are watching all bug changes.
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=10291 Galen Charlton <gmcharlt@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Passed QA |Pushed to Master CC| |gmcharlt@gmail.com --- Comment #8 from Galen Charlton <gmcharlt@gmail.com> --- Pushed to master. Thanks, Colin! -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org