mirror of
https://github.com/imputnet/cobalt.git
synced 2025-07-16 18:28:29 +00:00
allow redirects on default streams
This commit is contained in:
parent
8dcb6d8ea7
commit
465480d131
@ -16,7 +16,8 @@ export async function streamDefault(streamInfo, res) {
|
||||
res.setHeader('Content-disposition', `attachment; filename="${streamInfo.isAudioOnly ? `${streamInfo.filename}.${streamInfo.audioFormat}` : regFilename}"`);
|
||||
|
||||
const { body: stream, headers } = await request(streamInfo.urls, {
|
||||
headers: { 'user-agent': genericUserAgent }
|
||||
headers: { 'user-agent': genericUserAgent },
|
||||
maxRedirections: 16
|
||||
});
|
||||
|
||||
res.setHeader('content-type', headers['content-type']);
|
||||
|
Loading…
Reference in New Issue
Block a user