Browse Source

fix CvPdfRequestProcessor return value

olinox14 1 year ago
parent
commit
e2d5abcd65
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/State/Processor/CvPdfRequestProcessor.php

+ 2 - 2
src/State/Processor/CvPdfRequestProcessor.php

@@ -20,7 +20,7 @@ class CvPdfRequestProcessor implements ProcessorInterface
     )
     {}
 
-    public function process(mixed $data, Operation $operation, array $uriVariables = [], array $context = []): CvPdfRequest
+    public function process(mixed $data, Operation $operation, array $uriVariables = [], array $context = []): Response|RedirectResponse
     {
         if (!$operation instanceof Post) {
             throw new \RuntimeException('not supported', Response::HTTP_METHOD_NOT_ALLOWED);
@@ -59,6 +59,6 @@ class CvPdfRequestProcessor implements ProcessorInterface
             HeaderUtils::makeDisposition(HeaderUtils::DISPOSITION_ATTACHMENT, 'CV_Olivier_Massot.pdf')
         );
 
-        return $cvPdfRequest;
+        return $response;
     }
 }