From 6f98fc95d0ef772be2944e310cb13386a0ff6061 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Fri, 22 Nov 2024 17:11:07 +0000 Subject: [PATCH] Bug 37349: (follow-up) Cache the authority type, not just the key Test were failing because I neglected to store the value in the cache, I was only adding the cache key --- C4/Biblio.pm | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/C4/Biblio.pm b/C4/Biblio.pm index 6c62b21311a..6f36813c986 100644 --- a/C4/Biblio.pm +++ b/C4/Biblio.pm @@ -716,7 +716,10 @@ sub LinkBibHeadingsToAuthorities { $memory_cache->get_from_cache( "LinkBibHeadingsToAuthorities:AuthorityType:" . $heading->auth_type() ); unless ($authority_type) { $authority_type = Koha::Authority::Types->find( $heading->auth_type() ); - $memory_cache->set_in_cache( "LinkBibHeadingsToAuthorities:AuthorityType:" . $heading->auth_type() ); + $memory_cache->set_in_cache( + "LinkBibHeadingsToAuthorities:AuthorityType:" . $heading->auth_type(), + $authority_type + ); } if ( defined $current_link && (!$allowrelink || C4::Context->preference('LinkerKeepStale')) ) -- 2.39.5