From 0791c4f0254354401f5afd0103cfb1b0c5859237 Mon Sep 17 00:00:00 2001
From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Date: Fri, 8 Sep 2023 06:16:44 +0000
Subject: [PATCH] Bug 34339: (QA follow-up) Replace new by search in Licenses
Content-Type: text/plain; charset=utf-8

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
---
 Koha/REST/V1/ERM/Licenses.pm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Koha/REST/V1/ERM/Licenses.pm b/Koha/REST/V1/ERM/Licenses.pm
index 9408dfecae..616c10331c 100644
--- a/Koha/REST/V1/ERM/Licenses.pm
+++ b/Koha/REST/V1/ERM/Licenses.pm
@@ -55,7 +55,7 @@ sub get {
     my $c = shift->openapi->valid_input or return;
 
     return try {
-        my $license = $c->objects->find( Koha::ERM::Licenses->new, $c->param('license_id') );
+        my $license = $c->objects->find( Koha::ERM::Licenses->search, $c->param('license_id') );
 
         unless ($license) {
             return $c->render(
-- 
2.30.2