From 73ba110f6b66b71b0987b50bb6b2a7c65f6bcf62 Mon Sep 17 00:00:00 2001 From: Lucas Gass Date: Mon, 3 Nov 2025 18:11:42 +0000 Subject: [PATCH] Bug 34069: Log patron restoration --- Koha/Old/Patron.pm | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/Koha/Old/Patron.pm b/Koha/Old/Patron.pm index 88ef74f0057..61600e7bb1f 100644 --- a/Koha/Old/Patron.pm +++ b/Koha/Old/Patron.pm @@ -17,6 +17,8 @@ package Koha::Old::Patron; use Modern::Perl; +use C4::Log qw( logaction ); + use base qw(Koha::Object); =head1 NAME @@ -62,6 +64,14 @@ sub restore_deleted_borrower { # Delete the entry from deletedborrowers Koha::Old::Patrons->search( { borrowernumber => $patron_data->{borrowernumber} } )->delete; + # Log the restoration + logaction( + 'MEMBERS', + 'RESTORE', + $restored_patron->borrowernumber, + "Patron restored from deletedborrowers: " . $restored_patron->cardnumber + ) if C4::Context->preference('BorrowersLog'); + } ); -- 2.39.5