From 3d118fb501f576a298f6bb059167e4c7f4dd8dcc Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Fri, 30 Dec 2016 11:27:42 +0100 Subject: Server: propagate video update to other pods --- server/models/video.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'server/models') diff --git a/server/models/video.js b/server/models/video.js index 14fbe2f71..f51d08f06 100644 --- a/server/models/video.js +++ b/server/models/video.js @@ -111,10 +111,10 @@ module.exports = function (sequelize, DataTypes) { getDurationFromFile, list, listForApi, - listByHostAndRemoteId, listOwnedAndPopulateAuthorAndTags, listOwnedByAuthor, load, + loadByHostAndRemoteId, loadAndPopulateAuthor, loadAndPopulateAuthorAndPodAndTags, searchAndPopulateAuthorAndPodAndTags @@ -428,7 +428,7 @@ function listForApi (start, count, sort, callback) { }) } -function listByHostAndRemoteId (fromHost, remoteId, callback) { +function loadByHostAndRemoteId (fromHost, remoteId, callback) { const query = { where: { remoteId: remoteId @@ -449,7 +449,7 @@ function listByHostAndRemoteId (fromHost, remoteId, callback) { ] } - return this.findAll(query).asCallback(callback) + return this.findOne(query).asCallback(callback) } function listOwnedAndPopulateAuthorAndTags (callback) { -- cgit v1.2.3