From cba08ae38d22307e9182df28501db09ec001a734 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 12 Oct 2021 11:44:12 +0200 Subject: [PATCH] Bug 28700: Get from storage before log actions To make sure we have logging the values from DB --- C4/Log.pm | 3 +++ 1 file changed, 3 insertions(+) diff --git a/C4/Log.pm b/C4/Log.pm index 5a9077de0dd..15752b815b1 100644 --- a/C4/Log.pm +++ b/C4/Log.pm @@ -76,6 +76,9 @@ sub logaction { $usernumber ||= 0; $interface //= C4::Context->interface; + $infos = $infos->get_from_storage + if ref($infos) !~ /HASH|ARRAY/ && $infos->isa('Koha::Object'); + my $dbh = C4::Context->dbh; my $sth=$dbh->prepare("Insert into action_logs (timestamp,user,module,action,object,info,interface) values (now(),?,?,?,?,?,?)"); $sth->execute($usernumber,$modulename,$actionname,$objectnumber,$infos,$interface); -- 2.25.1