Small fix

This commit is contained in:
Pablo Ferreiro 2022-01-03 23:28:36 +01:00
parent fe3ae82100
commit 321ce20007
No known key found for this signature in database
GPG key ID: 41FBCE65B779FA24
3 changed files with 11 additions and 8 deletions

View file

@ -52,9 +52,12 @@ Route::add('/stream', function () use ($domains) {
}
if (isset($_GET['download'])) {
header('Content-Disposition: attachment; filename="tiktok.mp4"');
// Download
$downloader = new \Sovit\TikTok\Download();
$downloader->url($url,"tiktok-video",'mp4');
} else {
// Stream
$streamer = new \Sovit\TikTok\Stream();
$streamer->stream($url);
}
$streamer = new \Sovit\TikTok\Stream();
$streamer->stream($url);
});