diff options
-rw-r--r-- | src/library/scala/util/parsing/json/JSON.scala | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/library/scala/util/parsing/json/JSON.scala b/src/library/scala/util/parsing/json/JSON.scala index 96d541b0f2..07f48a6061 100644 --- a/src/library/scala/util/parsing/json/JSON.scala +++ b/src/library/scala/util/parsing/json/JSON.scala @@ -50,13 +50,16 @@ object JSON extends Parser { * A utility method to resolve a parsed JSON list into objects or * arrays. See the parse method for details. */ - def resolveType(input: List[Any]): Any = { + def resolveType(input: List[_]): Any = { var objMap = Map[String, Any]() if (input.forall { case (key: String, value: List[_]) => objMap += (key -> resolveType(value)) true + case (key : String, value : Any) => + objMap += (key -> value) + true case _ => false }) objMap else |