From f83413b07ec067e25320e1b2d8bd1d56d33c546e Mon Sep 17 00:00:00 2001 From: Suqatri <44299323+Suqatri@users.noreply.github.com> Date: Wed, 10 Jul 2024 20:41:36 +0200 Subject: [PATCH] improved cloud connector injection for java --- .../main/kotlin/dev/redicloud/api/utils/CloudJKWrapper.kt | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/apis/base-api/src/main/kotlin/dev/redicloud/api/utils/CloudJKWrapper.kt b/apis/base-api/src/main/kotlin/dev/redicloud/api/utils/CloudJKWrapper.kt index 02884bac..2bc26629 100644 --- a/apis/base-api/src/main/kotlin/dev/redicloud/api/utils/CloudJKWrapper.kt +++ b/apis/base-api/src/main/kotlin/dev/redicloud/api/utils/CloudJKWrapper.kt @@ -4,8 +4,9 @@ class CloudJKWrapper { companion object { @JvmStatic - fun injectCloudAPI(clazz: Class, cloudInjectable: T) { - injectApi(clazz, cloudInjectable) + fun injectCloudAPI(cloudInjectable: T) { + val cloudInjectableClazz: Class = cloudInjectable.javaClass + injectApi(cloudInjectableClazz, cloudInjectable) } @JvmStatic