Skip to content

Commit

Permalink
Fix enum MixinEnvironment.Option parsing always using the default
Browse files Browse the repository at this point in the history
  • Loading branch information
sfPlayer1 committed Sep 20, 2024
1 parent c067634 commit 511b5d4
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -629,7 +629,7 @@ final String getStringValue() {
<E extends Enum<E>> E getEnumValue(E defaultValue) {
String value = System.getProperty(this.property, defaultValue.name());
try {
return (E)Enum.valueOf(defaultValue.getClass(), value.toUpperCase(Locale.ROOT));
return (E)Enum.valueOf(defaultValue.getDeclaringClass(), value.toUpperCase(Locale.ROOT));
} catch (IllegalArgumentException ex) {
return defaultValue;
}
Expand Down

0 comments on commit 511b5d4

Please sign in to comment.