[Controller] Setting Content-type to image/jpeg
This commit is contained in:
parent
c1b702566b
commit
39532390e1
|
@ -31,7 +31,10 @@ class CaptchaController extends Controller
|
||||||
/* @var \Gregwar\CaptchaBundle\Generator\CaptchaGenerator $generator */
|
/* @var \Gregwar\CaptchaBundle\Generator\CaptchaGenerator $generator */
|
||||||
$generator = $this->container->get('gregwar_captcha.generator');
|
$generator = $this->container->get('gregwar_captcha.generator');
|
||||||
|
|
||||||
return new Response($generator->generate($key, $options));
|
$response = new Response($generator->generate($key, $options));
|
||||||
|
$response->headers->set('Content-type', 'image/jpeg');
|
||||||
|
|
||||||
|
return $response;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue