From 59c91b77809fdcd5e154c0726c218d39ae0bfbef Mon Sep 17 00:00:00 2001 From: OldHawk Date: Thu, 27 Apr 2017 18:38:34 +0800 Subject: [PATCH] fixed other torrents number wrong --- .../torrents/server/controllers/torrents.server.controller.js | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/torrents/server/controllers/torrents.server.controller.js b/modules/torrents/server/controllers/torrents.server.controller.js index 933b7e05..f36b08af 100644 --- a/modules/torrents/server/controllers/torrents.server.controller.js +++ b/modules/torrents/server/controllers/torrents.server.controller.js @@ -493,6 +493,7 @@ exports.torrentByID = function (req, res, next, id) { if (err) { callback(err); } else { + torrent._other_torrents.splice(0, torrent._other_torrents.length); torrents.forEach(function (t) { if (!t._id.equals(torrent._id)) { torrent._other_torrents.push(t);