aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java')
-rw-r--r--src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java b/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java
index 47daddb0..b7b7fe47 100644
--- a/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java
+++ b/src/main/java/de/thedevstack/conversationsplus/ConversationsPlusPreferences.java
@@ -253,7 +253,8 @@ public class ConversationsPlusPreferences extends Settings {
}
protected static <T extends Enum<T>> T getEnumFromStringPref(String key, T defaultValue) {
- return (T) T.valueOf(defaultValue.getClass(), defaultValue.name());
+ String enumValueAsString = getString(key, defaultValue.name());
+ return (T) Enum.valueOf(defaultValue.getClass(), enumValueAsString);
}
private static boolean getBoolean(String key, boolean defValue) {