private function openFileInBrowser($attachment, $attachmentService) { $file = $attachmentService->getStorageLocation($attachment); $response = new BinaryFileResponse($file); return $response; }