]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/blobdiff - server/lib/activitypub/share.ts
Process remaining segment hashes on live ending
[github/Chocobozzz/PeerTube.git] / server / lib / activitypub / share.ts
index e847c4b7d265c35ced580c13ea7e0eb33cd9f7c0..5e426f5dba499f5917b20128f466b0399eb503fa 100644 (file)
@@ -1,5 +1,4 @@
 import { Transaction } from 'sequelize'
-import { getServerActor } from '../../helpers/utils'
 import { VideoShareModel } from '../../models/video/video-share'
 import { sendUndoAnnounce, sendVideoAnnounce } from './send'
 import { getVideoAnnounceActivityPubUrl } from './url'
@@ -9,7 +8,8 @@ import { getOrCreateActorAndServerAndModel } from './actor'
 import { logger } from '../../helpers/logger'
 import { CRAWL_REQUEST_CONCURRENCY } from '../../initializers/constants'
 import { checkUrlsSameHost, getAPId } from '../../helpers/activitypub'
-import { MChannelActorLight, MVideo, MVideoAccountLight, MVideoId } from '../../typings/models/video'
+import { MChannelActorLight, MVideo, MVideoAccountLight, MVideoId } from '../../types/models/video'
+import { getServerActor } from '@server/models/application/application'
 
 async function shareVideoByServerAndChannel (video: MVideoAccountLight, t: Transaction) {
   if (!video.hasPrivacyForFederation()) return undefined
@@ -36,7 +36,7 @@ async function addVideoShares (shareUrls: string[], video: MVideoId) {
   await Bluebird.map(shareUrls, async shareUrl => {
     try {
       // Fetch url
-      const { body } = await doRequest({
+      const { body } = await doRequest<any>({
         uri: shareUrl,
         json: true,
         activityPub: true