Merge branch '2.0.10-SNAPSHOT' into develop
This commit is contained in:
commit
c6cadf345b
2 changed files with 2 additions and 2 deletions
2
pom.xml
2
pom.xml
|
@ -5,7 +5,7 @@
|
|||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>net.helenus</groupId>
|
||||
<artifactId>helenus-core</artifactId>
|
||||
<version>2.0.9-SNAPSHOT</version>
|
||||
<version>2.0.10-SNAPSHOT</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>helenus</name>
|
||||
|
|
|
@ -107,7 +107,7 @@ public class MapperInvocationHandler<E> implements InvocationHandler {
|
|||
|
||||
} else if (returnType.isEnum() && (value.getClass() == Integer.class || value.getClass() == int.class)) {
|
||||
try {
|
||||
value = returnType.getClass().getEnumConstants()[(int) value];
|
||||
value = Class.forName(returnType.getName()).getEnumConstants()[(Integer) value];
|
||||
} catch (ArrayIndexOutOfBoundsException e) {
|
||||
throw new IllegalArgumentException("invalid ordinal " + value + " for enum type " + returnType.getSimpleName());
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue