diff options
author | Chocobozzz <me@florianbigard.com> | 2017-12-28 08:49:08 +0100 |
---|---|---|
committer | Chocobozzz <me@florianbigard.com> | 2017-12-28 08:49:08 +0100 |
commit | f40bbe3146553ef45515ee6b6d93ce6028f045ca (patch) | |
tree | 0f4190e652864916c19b4c5bf1acea57108d068b /server/lib/activitypub | |
parent | d50acfab69ce9e05b272dea6c4d34d52960ba14c (diff) | |
download | PeerTube-f40bbe3146553ef45515ee6b6d93ce6028f045ca.tar.gz PeerTube-f40bbe3146553ef45515ee6b6d93ce6028f045ca.tar.zst PeerTube-f40bbe3146553ef45515ee6b6d93ce6028f045ca.zip |
Fix preview 404
Diffstat (limited to 'server/lib/activitypub')
-rw-r--r-- | server/lib/activitypub/videos.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/server/lib/activitypub/videos.ts b/server/lib/activitypub/videos.ts index ded854ee1..83f3e9933 100644 --- a/server/lib/activitypub/videos.ts +++ b/server/lib/activitypub/videos.ts | |||
@@ -22,7 +22,9 @@ function fetchRemoteVideoPreview (video: VideoModel, reject: Function) { | |||
22 | const host = video.VideoChannel.Account.Actor.Server.host | 22 | const host = video.VideoChannel.Account.Actor.Server.host |
23 | const path = join(STATIC_PATHS.PREVIEWS, video.getPreviewName()) | 23 | const path = join(STATIC_PATHS.PREVIEWS, video.getPreviewName()) |
24 | 24 | ||
25 | return request.get(REMOTE_SCHEME.HTTP + '://' + host + path, err => reject(err)) | 25 | return request.get(REMOTE_SCHEME.HTTP + '://' + host + path, err => { |
26 | if (err) reject(err) | ||
27 | }) | ||
26 | } | 28 | } |
27 | 29 | ||
28 | async function fetchRemoteVideoDescription (video: VideoModel) { | 30 | async function fetchRemoteVideoDescription (video: VideoModel) { |