Fixed bad object conversion to JSONObject
Merge remote-tracking branch 'vaneyck/master'