Skip to content

Commit 034df21

Browse files
author
Robin Duda
committed
CoreStrings: use pluginstring if plugin class fails loading
1 parent 3eac82c commit 034df21

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

core/main/java/com/codingchili/core/configuration/CoreStrings.java

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -424,8 +424,14 @@ public static String getIdentityNotConfigured(String name) {
424424
return "[" + name + "] Error: '" + ID_NODE + "' must be configured for token generation.";
425425
}
426426

427-
public static String getStorageLoaderError(Class plugin, String database, String collection) {
428-
return "Error: Failed to load storage plugin '" + plugin.getSimpleName() + "' for '" + database + DIR_SEPARATOR + collection + "'.";
427+
public static String getStorageLoaderError(String plugin, String database, String collection) {
428+
return String.format(
429+
"Error: Failed to load storage plugin '%s' for '%s%s%s'.",
430+
plugin,
431+
database,
432+
DIR_SEPARATOR,
433+
collection
434+
);
429435
}
430436

431437
public static String getErrorCreateDirectory(String target) {

0 commit comments

Comments
 (0)