Replace qualifier with import

This commit is contained in:
Jan-Marlon Leibl 2023-11-03 21:43:16 +01:00
parent e679d02b41
commit 602eeb49eb

@ -7,6 +7,7 @@ use App\Entity\User;
use App\Repository\UserRepository;
use DateTimeImmutable;
use Doctrine\ORM\EntityManagerInterface;
use Exception;
use RuntimeException;
use Symfony\Bundle\FrameworkBundle\Controller\AbstractController;
use Symfony\Component\HttpFoundation\File\UploadedFile;
@ -59,7 +60,7 @@ class UploadController extends AbstractController
$fileUrl = $this->generateFileUrl($newFilename);
return new Response($fileUrl, Response::HTTP_CREATED);
} catch (\Exception $exception) {
} catch (Exception $exception) {
return new JsonResponse(['error' => $exception->getMessage()], Response::HTTP_BAD_REQUEST);
}
}