console.log('Uploading %s video...', program[ 'videoName' ])
- let videoAttributes:any = {
+ const videoAttributes = {
name: program['videoName'],
category: program['category'],
+ channelId: program['channelId'],
licence: program['licence'],
language: program['language'],
nsfw: program['nsfw'],
support: undefined
}
- if (program['channelId']) {
- videoAttributes.channelId = program['channelId']
- }
-
await uploadVideo(program[ 'url' ], accessToken, videoAttributes)
console.log(`Video ${program['videoName']} uploaded.`)