Renamed method onJSONMessage to onJSON