X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=server%2Flib%2Factivitypub%2Fvideos.ts;h=ded854ee135034c8110d6915e3b73d07eff1c0fe;hb=d50acfab69ce9e05b272dea6c4d34d52960ba14c;hp=fab43757a443a1fa713fd9e722ed4b0e2700d276;hpb=50d6de9c286abcb34ff4234d56d9cbb803db7665;p=github%2FChocobozzz%2FPeerTube.git diff --git a/server/lib/activitypub/videos.ts b/server/lib/activitypub/videos.ts index fab43757a..ded854ee1 100644 --- a/server/lib/activitypub/videos.ts +++ b/server/lib/activitypub/videos.ts @@ -17,12 +17,12 @@ import { sendUndoLikeToVideoFollowers } from './send' -function fetchRemoteVideoPreview (video: VideoModel) { +function fetchRemoteVideoPreview (video: VideoModel, reject: Function) { // FIXME: use url const host = video.VideoChannel.Account.Actor.Server.host const path = join(STATIC_PATHS.PREVIEWS, video.getPreviewName()) - return request.get(REMOTE_SCHEME.HTTP + '://' + host + path) + return request.get(REMOTE_SCHEME.HTTP + '://' + host + path, err => reject(err)) } async function fetchRemoteVideoDescription (video: VideoModel) {