converting xml to Json with lift behaves strange
问题 I'm using scala / lift for a Rest API. Under the hood I'm generating xml which will be converted to json via Xml.toJson() as output. Now i noticed some strange behavior which drives me nuts. for example i have the following xml: <data> <item> <foo>1</foo> <bar>1</bar> </item> <item> <foo>2</foo> <bar>2</bar> </item> </data> the result of xml.toJson() looks like: JObject( List( JField( data,JObject( List( JField(item, JArray( List( JObject( List( JField(foo,JString(1)), JField(bar,JString(1)))