WebSocketModule: Fixed JSON parsing and handling for incoming messages.