From ff54da383e981a33f7736b013da5d76eb2cebc75 Mon Sep 17 00:00:00 2001 From: OldHawk Date: Tue, 8 May 2018 15:17:35 +0800 Subject: [PATCH] fix(score): do not log score if value is 0 --- config/lib/score.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/config/lib/score.js b/config/lib/score.js index c2953064..d4350c27 100644 --- a/config/lib/score.js +++ b/config/lib/score.js @@ -12,6 +12,7 @@ var path = require('path'), var traceConfig = config.meanTorrentConfig.trace; var examinationConfig = config.meanTorrentConfig.examination; var scoreConfig = config.meanTorrentConfig.score; +var mtDebug = require(path.resolve('./config/lib/debug')); /** * update @@ -23,6 +24,7 @@ var scoreConfig = config.meanTorrentConfig.score; */ module.exports.update = function (req, user, action, value, writeLog = true) { var v = value || action.value || 0; + mtDebug.info('scoreUpdate: score = ' + score); if (action.enable && v !== 0) { if (user) {