From 84c8ea3e2ce988b0f33f89a7694d50943c0c46df Mon Sep 17 00:00:00 2001 From: Lucas Gass Date: Thu, 5 Mar 2026 15:21:21 +0000 Subject: [PATCH] Bug 23269: (RM follow-up): Tidy --- koha-tmpl/intranet-tmpl/prog/js/holds.js | 10 ++++++++-- t/db_dependent/Koha/Holds.t | 6 ++++-- t/db_dependent/api/v1/holds.t | 2 +- 3 files changed, 13 insertions(+), 5 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/holds.js b/koha-tmpl/intranet-tmpl/prog/js/holds.js index 8ea41529d10..5a26ab57ccf 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/holds.js +++ b/koha-tmpl/intranet-tmpl/prog/js/holds.js @@ -1454,7 +1454,10 @@ async function load_patron_holds_table(biblio_id, split_data) { orderable: false, searchable: false, render: function (data, type, row, meta) { - if (row.status || !CAN_user_reserveforothers_modify_holds_priority) { + if ( + row.status || + !CAN_user_reserveforothers_modify_holds_priority + ) { return null; } let buttons = @@ -1673,7 +1676,10 @@ async function load_patron_holds_table(biblio_id, split_data) { orderable: false, searchable: false, render: function (data, type, row, meta) { - if (row.status || !CAN_user_reserveforothers_modify_holds_priority) { + if ( + row.status || + !CAN_user_reserveforothers_modify_holds_priority + ) { return null; } else { if (row.lowest_priority) { diff --git a/t/db_dependent/Koha/Holds.t b/t/db_dependent/Koha/Holds.t index 6780ab06932..40dd2b32065 100755 --- a/t/db_dependent/Koha/Holds.t +++ b/t/db_dependent/Koha/Holds.t @@ -466,7 +466,8 @@ subtest 'cancel' => sub { my $reserve_id = C4::Reserves::AddReserve($hold_info); Koha::Holds->find($reserve_id)->cancel; my $number_of_logs = - $schema->resultset('ActionLog')->search( { module => 'HOLDS', action => 'CANCEL', object => $reserve_id } ) + $schema->resultset('ActionLog') + ->search( { module => 'HOLDS', action => 'CANCEL', object => $reserve_id } ) ->count; is( $number_of_logs, 0, 'Without HoldsLog, Koha::Hold->cancel should not have logged' ); @@ -474,7 +475,8 @@ subtest 'cancel' => sub { $reserve_id = C4::Reserves::AddReserve($hold_info); Koha::Holds->find($reserve_id)->cancel; $number_of_logs = - $schema->resultset('ActionLog')->search( { module => 'HOLDS', action => 'CANCEL', object => $reserve_id } ) + $schema->resultset('ActionLog') + ->search( { module => 'HOLDS', action => 'CANCEL', object => $reserve_id } ) ->count; is( $number_of_logs, 1, 'With HoldsLog, Koha::Hold->cancel should have logged' ); }; diff --git a/t/db_dependent/api/v1/holds.t b/t/db_dependent/api/v1/holds.t index 9bfd04e6f84..65fb7df2f41 100755 --- a/t/db_dependent/api/v1/holds.t +++ b/t/db_dependent/api/v1/holds.t @@ -527,7 +527,7 @@ subtest 'suspend and resume tests' => sub { ->json_is( '/end_date', output_pref( { dt => $date, dateformat => 'iso', dateonly => 1 } ) - )->header_is( Location => "/api/v1/holds/" . $hold->id . "/suspension", 'The Location header is set' ); + )->header_is( Location => "/api/v1/holds/" . $hold->id . "/suspension", 'The Location header is set' ); $t->delete_ok( "//$userid:$password@/api/v1/holds/" . $hold->id . "/suspension" ) ->status_is( 204, 'REST3.2.4' ) -- 2.39.5