mirror of
https://github.com/Chocobozzz/PeerTube.git
synced 2025-10-05 02:39:33 +02:00
Correctly cleanup files from object storage
This commit is contained in:
parent
849f0fd3b2
commit
508c1b1e9f
4 changed files with 42 additions and 19 deletions
|
@ -4,7 +4,7 @@ import { expect } from 'chai'
|
|||
import { createReadStream, stat } from 'fs-extra'
|
||||
import got, { Response as GotResponse } from 'got'
|
||||
import validator from 'validator'
|
||||
import { buildAbsoluteFixturePath, omit, pick, wait } from '@shared/core-utils'
|
||||
import { buildAbsoluteFixturePath, getAllPrivacies, omit, pick, wait } from '@shared/core-utils'
|
||||
import { buildUUID } from '@shared/extra-utils'
|
||||
import {
|
||||
HttpStatusCode,
|
||||
|
@ -15,6 +15,7 @@ import {
|
|||
VideoCreateResult,
|
||||
VideoDetails,
|
||||
VideoFileMetadata,
|
||||
VideoInclude,
|
||||
VideoPrivacy,
|
||||
VideosCommonQuery,
|
||||
VideoTranscodingCreate
|
||||
|
@ -234,6 +235,22 @@ export class VideosCommand extends AbstractCommand {
|
|||
})
|
||||
}
|
||||
|
||||
listAllForAdmin (options: OverrideCommandOptions & VideosCommonQuery = {}) {
|
||||
const include = VideoInclude.NOT_PUBLISHED_STATE | VideoInclude.BLACKLISTED | VideoInclude.BLOCKED_OWNER
|
||||
const nsfw = 'both'
|
||||
const privacyOneOf = getAllPrivacies()
|
||||
|
||||
return this.list({
|
||||
...options,
|
||||
|
||||
include,
|
||||
nsfw,
|
||||
privacyOneOf,
|
||||
|
||||
token: this.buildCommonRequestToken({ ...options, implicitToken: true })
|
||||
})
|
||||
}
|
||||
|
||||
listByAccount (options: OverrideCommandOptions & VideosCommonQuery & {
|
||||
handle: string
|
||||
}) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue