public function injectResponse(ViewEvent $e)
    {
        $model = $e->getModel();
        if ($model instanceof ImageModel) {
            $result   = $e->getResult();

            $response = $e->getResponse();
            $response->setContent($result);

            $response->getHeaders()->addHeaderLine('Content-type', $this->getMimeType($model->getFormat()));
        }
    }