https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=23112
--- Comment #50 from Andrew Isherwood <[email protected]> --- (In reply to Jonathan Druart from comment #48) > (In reply to Andrew Isherwood from comment #46) > > > ::: Koha/Illrequest.pm > > > @@ +1211,5 @@ > > > > + # For some reason, AddIssue requires an unblessed Patron > > > > + $issue_args[0] = $patron->unblessed; > > > > + my $issue = C4::Circulation::AddIssue(@issue_args); > > > > + > > > > + if ($issue && %{$issue}) { > > > > > > AddIssue return a Koha::Checkout object. The test will work but I think > > > it's > > > confusing. > > > > Do you mean the variable name $issue is confusing? If so, I thought it made > > sense since the function returning it is called AddIssue and, internally, > > AddIssue also calls the returned value $issue. > > You should only test for $issue, the "&& %$issue" does not make sense to me. I've now attached a patch to address this. I'm puzzled why I did this extra test, it seems like the sort of thing that would be deliberate. Looking at AddIssue, I can't see a case where an empty hashref could be returned, so I'm not sure why I would have added this extra test. Anyway, thanks for pointing it out Jonathan. -- You are receiving this mail because: You are watching all bug changes. _______________________________________________ Koha-bugs mailing list [email protected] https://lists.koha-community.org/cgi-bin/mailman/listinfo/koha-bugs website : http://www.koha-community.org/ git : http://git.koha-community.org/ bugs : http://bugs.koha-community.org/
