Bugzilla – Attachment 61751 Details for
Bug 18332
Add the Koha::Objects->last method
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 18332: [QA Follow-up] Adjust slice call in last method
Bug-18332-QA-Follow-up-Adjust-slice-call-in-last-m.patch (text/plain), 965 bytes, created by
Marcel de Rooy
on 2017-03-31 07:34:57 UTC
(
hide
)
Description:
Bug 18332: [QA Follow-up] Adjust slice call in last method
Filename:
MIME Type:
Creator:
Marcel de Rooy
Created:
2017-03-31 07:34:57 UTC
Size:
965 bytes
patch
obsolete
>From 71c7e4b3fff5530b3c2111cb9a7daecb676a38b7 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Fri, 31 Mar 2017 09:32:53 +0200 >Subject: [PATCH] Bug 18332: [QA Follow-up] Adjust slice call in last method >Content-Type: text/plain; charset=utf-8 > >We should call slice in list context with the correct indexes. > >Test plan: >Run t/db_dependent/Koha/Objects.t > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >--- > Koha/Objects.pm | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > >diff --git a/Koha/Objects.pm b/Koha/Objects.pm >index 1a52188..41fee35 100644 >--- a/Koha/Objects.pm >+++ b/Koha/Objects.pm >@@ -220,7 +220,7 @@ sub last { > my $count = $self->_resultset->count; > return unless $count; > >- my $result = $self->_resultset->slice($count - 1, $count)->first; >+ my ( $result ) = $self->_resultset->slice($count - 1, $count - 1); > > my $object = $self->object_class()->_new_from_dbic( $result ); > >-- >2.1.4
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 18332
:
61625
|
61626
|
61636
|
61694
| 61751