mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-04 10:19:35 +02:00
Support reinjecting token in private m3u8 playlist
This commit is contained in:
parent
04509c4325
commit
71e3e879c0
22 changed files with 391 additions and 48 deletions
|
@ -7,16 +7,24 @@ export class StreamingPlaylistsCommand extends AbstractCommand {
|
|||
|
||||
async get (options: OverrideCommandOptions & {
|
||||
url: string
|
||||
|
||||
videoFileToken?: string
|
||||
reinjectVideoFileToken?: boolean
|
||||
|
||||
withRetry?: boolean // default false
|
||||
currentRetry?: number
|
||||
}) {
|
||||
const { withRetry, currentRetry = 1 } = options
|
||||
const { videoFileToken, reinjectVideoFileToken, withRetry, currentRetry = 1 } = options
|
||||
|
||||
try {
|
||||
const result = await unwrapTextOrDecode(this.getRawRequest({
|
||||
...options,
|
||||
|
||||
url: options.url,
|
||||
query: {
|
||||
videoFileToken,
|
||||
reinjectVideoFileToken
|
||||
},
|
||||
implicitToken: false,
|
||||
defaultExpectedStatus: HttpStatusCode.OK_200
|
||||
}))
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue