From 0d2db40e02eb17e8d0c027cfef72ab0f74483c3d Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Thu, 2 Mar 2017 16:35:35 +0900 Subject: [PATCH] Don't double-subtract points when deleting document or comment with attached files --- modules/point/point.controller.php | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/modules/point/point.controller.php b/modules/point/point.controller.php index c30285771..36a6aa657 100644 --- a/modules/point/point.controller.php +++ b/modules/point/point.controller.php @@ -265,16 +265,6 @@ class pointController extends point $cur_point -= $document_point; } - // Subtract points for attached files. - if ($obj->uploaded_count > 0) - { - $attached_files_point = $this->_getModulePointConfig($module_srl, 'upload_file'); - if ($attached_files_point > 0) - { - $cur_point -= $attached_files_point * $obj->uploaded_count; - } - } - // Increase the point. $this->setPoint($member_srl, $cur_point); return new Object(); @@ -358,16 +348,6 @@ class pointController extends point $comment_point = $this->_getModulePointConfig($module_srl, 'insert_comment'); $cur_point -= $comment_point; - // Subtract points for attached files. - if ($obj->uploaded_count > 0) - { - $attached_files_point = $this->_getModulePointConfig($module_srl, 'upload_file'); - if ($attached_files_point > 0) - { - $cur_point -= $attached_files_point * $obj->uploaded_count; - } - } - // Increase the point. $this->setPoint($member_srl, $cur_point); return new Object();