From 00d2f0e199be7743102e1202ccfb409e344913e9 Mon Sep 17 00:00:00 2001 From: Pierre Rudloff Date: Tue, 2 May 2017 11:20:36 +0200 Subject: [PATCH] getAvconvMp3Process should return a Process --- classes/VideoDownload.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/classes/VideoDownload.php b/classes/VideoDownload.php index 0d42a97..92ee07d 100644 --- a/classes/VideoDownload.php +++ b/classes/VideoDownload.php @@ -253,7 +253,7 @@ class VideoDownload throw(new \Exception('Can\'t find avconv or ffmpeg')); } - return ProcessBuilder::create( + $builder = ProcessBuilder::create( [ $this->config->avconv, '-v', 'quiet', @@ -265,6 +265,8 @@ class VideoDownload 'pipe:1', ] ); + + return $builder->getProcess(); } /** @@ -292,7 +294,7 @@ class VideoDownload } else { $avconvProc = $this->getAvconvMp3Process($video->url); - return popen($avconvProc->getProcess()->getCommandLine(), 'r'); + return popen($avconvProc->getCommandLine(), 'r'); } }