getAvconvMp3Process should return a Process
This commit is contained in:
parent
b36efb3929
commit
00d2f0e199
1 changed files with 4 additions and 2 deletions
|
@ -253,7 +253,7 @@ class VideoDownload
|
||||||
throw(new \Exception('Can\'t find avconv or ffmpeg'));
|
throw(new \Exception('Can\'t find avconv or ffmpeg'));
|
||||||
}
|
}
|
||||||
|
|
||||||
return ProcessBuilder::create(
|
$builder = ProcessBuilder::create(
|
||||||
[
|
[
|
||||||
$this->config->avconv,
|
$this->config->avconv,
|
||||||
'-v', 'quiet',
|
'-v', 'quiet',
|
||||||
|
@ -265,6 +265,8 @@ class VideoDownload
|
||||||
'pipe:1',
|
'pipe:1',
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|
||||||
|
return $builder->getProcess();
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -292,7 +294,7 @@ class VideoDownload
|
||||||
} else {
|
} else {
|
||||||
$avconvProc = $this->getAvconvMp3Process($video->url);
|
$avconvProc = $this->getAvconvMp3Process($video->url);
|
||||||
|
|
||||||
return popen($avconvProc->getProcess()->getCommandLine(), 'r');
|
return popen($avconvProc->getCommandLine(), 'r');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue