getRequestFormat() === 'json') { return new JsonResponse(array('content' => 'oh hai this is json')); } else { return new Response("

oh hai this is html.

"); } } }