Trivial code householding
- Replace `if (!x) ... else ...` with `if(x) ... else ...` - Avoid throwing RuntimeException; use children
This commit is contained in:
@@ -24,7 +24,7 @@ class EnumProperty<E extends Enum<E>> extends Property<E> {
|
||||
return getDefaultValue();
|
||||
}
|
||||
E mappedValue = mapToEnum(textValue);
|
||||
return mappedValue != null ? mappedValue : getDefaultValue();
|
||||
return mappedValue == null ? getDefaultValue() : mappedValue;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in New Issue
Block a user