From f0910d4443bdaf2180662af55d33f36e925efda5 Mon Sep 17 00:00:00 2001 From: Wikum Weerakutti Date: Fri, 22 Nov 2024 22:23:13 +0900 Subject: [PATCH] TRUNK-6287: Fix Exception Propagation Issue in ServiceContext.getRegisteredComponent Method (#4843) --- api/src/main/java/org/openmrs/api/context/ServiceContext.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/api/src/main/java/org/openmrs/api/context/ServiceContext.java b/api/src/main/java/org/openmrs/api/context/ServiceContext.java index 7f5b2ef24ab7..c2be359e4d69 100644 --- a/api/src/main/java/org/openmrs/api/context/ServiceContext.java +++ b/api/src/main/java/org/openmrs/api/context/ServiceContext.java @@ -904,7 +904,7 @@ public T getRegisteredComponent(String beanName, Class type) throws APIEx return applicationContext.getBean(beanName, type); } catch (BeansException beanException) { - throw new APIException("service.error.during.getting.component", null, beanException); + throw new APIException("Error during getting registered component", beanException); } }