{"action":"opened","issue":{"url":"https://api.github.com/repos/mailjet/mailjet-gem/issues/42","labels_url":"https://api.github.com/repos/mailjet/mailjet-gem/issues/42/labels{/name}","comments_url":"https://api.github.com/repos/mailjet/mailjet-gem/issues/42/comments","events_url":"https://api.github.com/repos/mailjet/mailjet-gem/issues/42/events","html_url":"https://github.com/mailjet/mailjet-gem/issues/42","id":81476645,"number":42,"title":"exception handling failure when content_type is set to json","user":{"login":"Electron-libre","id":5979,"avatar_url":"https://avatars.githubusercontent.com/u/5979?v=3","gravatar_id":"","url":"https://api.github.com/users/Electron-libre","html_url":"https://github.com/Electron-libre","followers_url":"https://api.github.com/users/Electron-libre/followers","following_url":"https://api.github.com/users/Electron-libre/following{/other_user}","gists_url":"https://api.github.com/users/Electron-libre/gists{/gist_id}","starred_url":"https://api.github.com/users/Electron-libre/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Electron-libre/subscriptions","organizations_url":"https://api.github.com/users/Electron-libre/orgs","repos_url":"https://api.github.com/users/Electron-libre/repos","events_url":"https://api.github.com/users/Electron-libre/events{/privacy}","received_events_url":"https://api.github.com/users/Electron-libre/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2015-05-27T14:43:53Z","updated_at":"2015-05-27T14:43:53Z","closed_at":null,"body":"in `Mailjet::Connection#handle_api_call`\r\nwhen exception occur and \r\n```ruby\r\nadditional_headers[:content_type]\r\n=> :json\r\n```\r\njson parsed payload is passed to `Mailjet::Connection#handle_exception` which expect it as hash, not json string.\r\n\r\nThis result in\r\n```\r\nTypeError: can't convert String into Hash\r\nfrom /home/cedric/Projects/Synbioz/Odcvl/odcvl/vendor/bundle/ruby/1.9.1/bundler/gems/mailjet-gem-1d7045ebb97b/lib/mailjet/connection.rb:74:in `merge'\r\n\r\n```"}}