mirror of
https://github.com/ethauvin/JSON-java.git
synced 2025-06-17 07:50:52 -07:00
Java 1.6 compatibility.
This commit is contained in:
parent
ba2585fe6c
commit
60349ece54
2 changed files with 8 additions and 4 deletions
|
@ -93,7 +93,7 @@ import java.util.Set;
|
|||
* </ul>
|
||||
*
|
||||
* @author JSON.org
|
||||
* @version 2015-01-30
|
||||
* @version 2016-02-08
|
||||
*/
|
||||
public class JSONObject {
|
||||
/**
|
||||
|
@ -901,7 +901,9 @@ public class JSONObject {
|
|||
return myE;
|
||||
}
|
||||
return Enum.valueOf(clazz, val.toString());
|
||||
} catch (IllegalArgumentException | NullPointerException e) {
|
||||
} catch (IllegalArgumentException e) {
|
||||
return defaultValue;
|
||||
} catch (NullPointerException e) {
|
||||
return defaultValue;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue