]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/lib/activitypub/send/send-update.ts
Add refresh video on search
[github/Chocobozzz/PeerTube.git] / server / lib / activitypub / send / send-update.ts
index 2fd374ec65312fd068f9fded3abdab243a34f07f..17d4f185c9464ad973ab9416053222e60ff1883f 100644 (file)
@@ -9,8 +9,11 @@ import { VideoShareModel } from '../../../models/video/video-share'
 import { getUpdateActivityPubUrl } from '../url'
 import { broadcastToFollowers } from './utils'
 import { audiencify, getAudience } from '../audience'
+import { logger } from '../../../helpers/logger'
 
 async function sendUpdateVideo (video: VideoModel, t: Transaction) {
+  logger.info('Creating job to update video %s.', video.url)
+
   const byActor = video.VideoChannel.Account.Actor
 
   const url = getUpdateActivityPubUrl(video.url, video.updatedAt.toISOString())
@@ -28,6 +31,8 @@ async function sendUpdateVideo (video: VideoModel, t: Transaction) {
 async function sendUpdateActor (accountOrChannel: AccountModel | VideoChannelModel, t: Transaction) {
   const byActor = accountOrChannel.Actor
 
+  logger.info('Creating job to update actor %s.', byActor.url)
+
   const url = getUpdateActivityPubUrl(byActor.url, byActor.updatedAt.toISOString())
   const accountOrChannelObject = accountOrChannel.toActivityPubObject()
   const audience = getAudience(byActor)