From 83c18ad623f90b4817164b76235445d6b2356c98 Mon Sep 17 00:00:00 2001 From: thrillfall Date: Sun, 22 Aug 2021 21:59:45 +0200 Subject: [PATCH] narrow catch to nextcloud dbal exceptions --- lib/Controller/EpisodeActionController.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Controller/EpisodeActionController.php b/lib/Controller/EpisodeActionController.php index 69ecafe..a0e0787 100644 --- a/lib/Controller/EpisodeActionController.php +++ b/lib/Controller/EpisodeActionController.php @@ -70,7 +70,7 @@ class EpisodeActionController extends Controller { return $this->episodeActionWriter->save($episodeActionEntity); } catch (UniqueConstraintViolationException $uniqueConstraintViolationException) { return $this->updateEpisodeAction($episodeAction, $episodeActionEntity); - } catch (\Exception $exception) { + } catch (Exception $exception) { if ($exception->getReason() === Exception::REASON_UNIQUE_CONSTRAINT_VIOLATION) { return $this->updateEpisodeAction($episodeAction, $episodeActionEntity); }