Update DefaultController.php

setAllowOriginHeader allow Response but the other functions always send JsonResponse