Clearer video creation from API regarding rates
This commit is contained in:
parent
1a99dc647f
commit
b89b0bfce9
|
@ -24,7 +24,7 @@ export class APVideoCreator extends APVideoAbstractBuilder {
|
|||
const channel = channelActor.VideoChannel
|
||||
|
||||
const videoData = getVideoAttributesFromObject(channel, this.videoObject, this.videoObject.to)
|
||||
const video = VideoModel.build(videoData) as MVideoThumbnail
|
||||
const video = VideoModel.build({ ...videoData, likes: 0, dislikes: 0 }) as MVideoThumbnail
|
||||
|
||||
const promiseThumbnail = this.tryToGenerateThumbnail(video)
|
||||
|
||||
|
|
|
@ -210,8 +210,6 @@ function getVideoAttributesFromObject (videoChannel: MChannelId, videoObject: Vi
|
|||
|
||||
updatedAt: new Date(videoObject.updated),
|
||||
views: videoObject.views,
|
||||
likes: 0,
|
||||
dislikes: 0,
|
||||
remote: true,
|
||||
privacy
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue