Bugzilla – Attachment 155799 Details for
Bug 34786
after_biblio_action hooks: find after delete makes no sense
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 34786: after_biblio_action hooks - No find when action is delete
Bug-34786-afterbiblioaction-hooks---No-find-when-a.patch (text/plain), 1.03 KB, created by
Martin Renvoize
on 2023-09-18 11:04:53 UTC
(
hide
)
Description:
Bug 34786: after_biblio_action hooks - No find when action is delete
Filename:
MIME Type:
Creator:
Martin Renvoize
Created:
2023-09-18 11:04:53 UTC
Size:
1.03 KB
patch
obsolete
>From f82f636de580ec88521f4a6ed4dd51d80b338871 Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Thu, 14 Sep 2023 09:11:56 +0000 >Subject: [PATCH] Bug 34786: after_biblio_action hooks - No find when action is > delete > >Test plan: >Run t/db_dependent/Koha/Plugins/Biblio_and_Items_plugin_hooks.t > >Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com> >--- > C4/Biblio.pm | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/C4/Biblio.pm b/C4/Biblio.pm >index c64a721c77c..a0e942f79ee 100644 >--- a/C4/Biblio.pm >+++ b/C4/Biblio.pm >@@ -3169,9 +3169,9 @@ sub _after_biblio_action_hooks { > my ( $args ) = @_; > > my $biblio_id = $args->{biblio_id}; >- my $action = $args->{action}; >+ my $action = $args->{action} // q{}; > >- my $biblio = Koha::Biblios->find( $biblio_id ); >+ my $biblio = $action ne 'delete' ? Koha::Biblios->find($biblio_id) : undef; > Koha::Plugins->call( > 'after_biblio_action', > { >-- >2.41.0
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 34786
:
155605
| 155799