Bugzilla – Attachment 157103 Details for
Bug 31846
Allow setting serials search results limit
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 31846: (QA follow-up) Tidy code to make qa script happy
Bug-31846-QA-follow-up-Tidy-code-to-make-qa-script.patch (text/plain), 2.14 KB, created by
Kyle M Hall (khall)
on 2023-10-13 13:56:55 UTC
(
hide
)
Description:
Bug 31846: (QA follow-up) Tidy code to make qa script happy
Filename:
MIME Type:
Creator:
Kyle M Hall (khall)
Created:
2023-10-13 13:56:55 UTC
Size:
2.14 KB
patch
obsolete
>From aa07e658681e42db8321d6d263b73cedb7248599 Mon Sep 17 00:00:00 2001 >From: Kyle M Hall <kyle@bywatersolutions.com> >Date: Fri, 13 Oct 2023 09:56:00 -0400 >Subject: [PATCH] Bug 31846: (QA follow-up) Tidy code to make qa script happy > >Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com> >--- > C4/Serials.pm | 4 ++-- > .../bug-31846-serials-search-results-limit.pl | 14 +++++++++----- > 2 files changed, 11 insertions(+), 7 deletions(-) > >diff --git a/C4/Serials.pm b/C4/Serials.pm >index dfa93ce1cab..ec88b0f3e63 100644 >--- a/C4/Serials.pm >+++ b/C4/Serials.pm >@@ -628,8 +628,8 @@ sub SearchSubscriptions { > > my $total_results = @{$results}; > >- if ($params->{results_limit} && $total_results > $params->{results_limit}) { >- $results = [splice(@{$results}, 0, $params->{results_limit})]; >+ if ( $params->{results_limit} && $total_results > $params->{results_limit} ) { >+ $results = [ splice( @{$results}, 0, $params->{results_limit} ) ]; > } > > for my $subscription ( @$results ) { >diff --git a/installer/data/mysql/atomicupdate/bug-31846-serials-search-results-limit.pl b/installer/data/mysql/atomicupdate/bug-31846-serials-search-results-limit.pl >index d7309af9009..30a8b2ef26c 100755 >--- a/installer/data/mysql/atomicupdate/bug-31846-serials-search-results-limit.pl >+++ b/installer/data/mysql/atomicupdate/bug-31846-serials-search-results-limit.pl >@@ -1,16 +1,20 @@ > use Modern::Perl; > > return { >- bug_number => "31846", >+ bug_number => "31846", > description => "Add SerialsSearchResultsLimit syspref", >- up => sub { >+ up => sub { > my ($args) = @_; >- my ($dbh, $out) = @$args{qw(dbh out)}; >+ my ( $dbh, $out ) = @$args{qw(dbh out)}; >+ > # Do you stuffs here >- $dbh->do(q{ >+ $dbh->do( >+ q{ > INSERT IGNORE INTO systempreferences (variable, value, options, explanation, type) > VALUES ('SerialsSearchResultsLimit', NULL, NULL, 'Serials search results limit', 'integer') >- }); >+ } >+ ); >+ > # Print useful stuff here > say $out "SerialsSearchResultsLimit syspref added"; > }, >-- >2.30.2
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 31846
:
141998
|
141999
|
154563
|
157102
| 157103