mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-17 11:18:01 +00:00
Simple fix for issue where the case of lifeloss for afflict creatures did not match apiType case, causing crashes
This commit is contained in:
@@ -168,7 +168,7 @@ public enum ApiType {
|
|||||||
|
|
||||||
static {
|
static {
|
||||||
for(ApiType t : ApiType.values()) {
|
for(ApiType t : ApiType.values()) {
|
||||||
allValues.put(t.name(), t);
|
allValues.put(t.name().toLowerCase(), t);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -179,7 +179,7 @@ public enum ApiType {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static ApiType smartValueOf(String value) {
|
public static ApiType smartValueOf(String value) {
|
||||||
ApiType v = allValues.get(value);
|
ApiType v = allValues.get(value.toLowerCase());
|
||||||
if ( v == null )
|
if ( v == null )
|
||||||
throw new RuntimeException("Element " + value + " not found in ApiType enum");
|
throw new RuntimeException("Element " + value + " not found in ApiType enum");
|
||||||
return v;
|
return v;
|
||||||
|
|||||||
Reference in New Issue
Block a user