{"action":"opened","issue":{"url":"https://api.github.com/repos/jtrumbull/XMLParser/issues/1","labels_url":"https://api.github.com/repos/jtrumbull/XMLParser/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/jtrumbull/XMLParser/issues/1/comments","events_url":"https://api.github.com/repos/jtrumbull/XMLParser/issues/1/events","html_url":"https://github.com/jtrumbull/XMLParser/issues/1","id":98385024,"number":1,"title":"bug in decoder","user":{"login":"nimasdj","id":6756021,"avatar_url":"https://avatars.githubusercontent.com/u/6756021?v=3","gravatar_id":"","url":"https://api.github.com/users/nimasdj","html_url":"https://github.com/nimasdj","followers_url":"https://api.github.com/users/nimasdj/followers","following_url":"https://api.github.com/users/nimasdj/following{/other_user}","gists_url":"https://api.github.com/users/nimasdj/gists{/gist_id}","starred_url":"https://api.github.com/users/nimasdj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nimasdj/subscriptions","organizations_url":"https://api.github.com/users/nimasdj/orgs","repos_url":"https://api.github.com/users/nimasdj/repos","events_url":"https://api.github.com/users/nimasdj/events{/privacy}","received_events_url":"https://api.github.com/users/nimasdj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-07-31T12:53:48Z","updated_at":"2015-07-31T12:53:48Z","closed_at":null,"body":"It seems there is a bug in decoder, consider this xml:\r\n```xml\r\n<?xml version=\"1.0\" encoding=\"UTF-8\"?>\r\n<loginshare>\r\n<result>1</result>\r\n<user>\r\n<usergroup>Registered</usergroup>\r\n<fullname>haha</fullname>\r\n<emails>\r\n<email>hhs@dhdh.com</email>\r\n<name>hg</name>\r\n</emails>\r\n</user>\r\n</loginshare>\r\n```\r\n\r\nIt turns it to this array:\r\n\r\n```\r\nArray\r\n(\r\n    [result] => 1\r\n    [user] => Array\r\n        (\r\n            [usergroup] => Registered\r\n            [fullname] => haha\r\n            [emails] => Array\r\n                (\r\n                    [email] => hhs@dhdh.com\r\n                    [name] => hg\r\n                    [0] => \r\n                )\r\n            [0] => \r\n        )\r\n)\r\n```\r\n\r\nWhy this [0] element array is there? encoding back this array will result in <item/> in xml.\r\nWould you fix it?\r\n"}}