From 8b2f900e504b91f00a5e861535d1875aa9cfdfe0 Mon Sep 17 00:00:00 2001 From: Varun Patil Date: Tue, 7 Mar 2023 20:46:20 -0800 Subject: [PATCH] video; ensure transcoder is a file --- lib/Controller/VideoController.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/Controller/VideoController.php b/lib/Controller/VideoController.php index f7603128..b18f46ce 100644 --- a/lib/Controller/VideoController.php +++ b/lib/Controller/VideoController.php @@ -239,6 +239,11 @@ class VideoController extends ApiBase throw new \Exception('Transcoder not configured'); } + // Make sure transcoder exists + if (!file_exists($transcoder)) { + throw new \Exception("Transcoder not found; run occ memories video-setup! ({$transcoder})"); + } + // Make transcoder executable if (!is_executable($transcoder)) { @chmod($transcoder, 0755);