Ensure Request::$data is always an array

This fixes the behaviour of JSON requests which were previously storing data in the request as an object (of type stdClass) rather than as an array which appeared to be the correct behaviour.