1
0
Fork 0
mirror of https://github.com/Chocobozzz/PeerTube.git synced 2025-10-04 10:19:35 +02:00

Add import.video.torrent configuration

This commit is contained in:
Chocobozzz 2018-08-07 10:07:53 +02:00
parent 990b6a0b0c
commit a84b8fa5cf
23 changed files with 112 additions and 106 deletions

View file

@ -9,7 +9,7 @@ import { CONFIG, CONSTRAINTS_FIELDS, reloadConfig } from '../../initializers'
import { asyncMiddleware, authenticate, ensureUserHasRight } from '../../middlewares'
import { customConfigUpdateValidator } from '../../middlewares/validators/config'
import { ClientHtml } from '../../lib/client-html'
import { CustomConfigAuditView, auditLoggerFactory } from '../../helpers/audit-logger'
import { auditLoggerFactory, CustomConfigAuditView } from '../../helpers/audit-logger'
const packageJSON = require('../../../../package.json')
const configRouter = express.Router()
@ -69,6 +69,9 @@ async function getConfig (req: express.Request, res: express.Response, next: exp
videos: {
http: {
enabled: CONFIG.IMPORT.VIDEOS.HTTP.ENABLED
},
torrent: {
enabled: CONFIG.IMPORT.VIDEOS.TORRENT.ENABLED
}
}
},
@ -237,6 +240,9 @@ function customConfig (): CustomConfig {
videos: {
http: {
enabled: CONFIG.IMPORT.VIDEOS.HTTP.ENABLED
},
torrent: {
enabled: CONFIG.IMPORT.VIDEOS.TORRENT.ENABLED
}
}
}