1
0
Fork 0

Remove unnecessary actor existance check

We already checked it in the signature checker
This commit is contained in:
Chocobozzz 2018-09-21 09:41:05 +02:00
parent f2659ae0b0
commit 1cfa8d6809
No known key found for this signature in database
GPG Key ID: 583A612D890159BE
4 changed files with 2 additions and 12 deletions

View File

@ -1 +0,0 @@
*.json

View File

@ -1,8 +0,0 @@
printWidth: 140
tabWidth: 2
useTabs: false
semi: false
singleQuote: true
trailingComma: false
bracketSpacing: true
arrowParens: always

View File

@ -90,9 +90,6 @@ async function processCreateView (byActor: ActorModel, activity: ActivityCreate)
}
const { video } = await getOrCreateVideoAndAccountAndChannel(options)
const actorExists = await ActorModel.isActorUrlExist(view.actor)
if (actorExists === false) throw new Error('Unknown actor ' + view.actor)
await Redis.Instance.addVideoView(video.id)
if (video.isOwned()) {

View File

@ -30,6 +30,8 @@ export class VideosRedundancyScheduler extends AbstractScheduler {
this.executing = true
for (const obj of CONFIG.REDUNDANCY.VIDEOS.STRATEGIES) {
if (!isTestInstance()) logger.info('Running redundancy scheduler for strategy %s.', obj.strategy)
try {
const videoToDuplicate = await this.findVideoToDuplicate(obj)
if (!videoToDuplicate) continue