From 717ab0a8ab7bd72de8459a650cf27c0ccbfd1c8c Mon Sep 17 00:00:00 2001 From: sejin7940 Date: Sat, 30 Aug 2014 20:48:12 +0900 Subject: [PATCH] Update point.controller.php --- modules/point/point.controller.php | 25 +++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) diff --git a/modules/point/point.controller.php b/modules/point/point.controller.php index b3f32b9a3..abbefbdb1 100644 --- a/modules/point/point.controller.php +++ b/modules/point/point.controller.php @@ -456,15 +456,32 @@ class pointController extends point if( $obj->point > 0 ) { - $point = $module_config['voted']; - if(strlen($point) == 0 && !is_int($point)) $point = $config->voted; + if($obj->comment_srl) + { + $point = $module_config['voted_comment']; + if(strlen($point) == 0 && !is_int($point)) $point = $config->voted_comment; + } + else + { + $point = $module_config['voted']; + if(strlen($point) == 0 && !is_int($point)) $point = $config->voted; + } } else { - $point = $module_config['blamed']; - if(strlen($point) == 0 && !is_int($point)) $point = $config->blamed; + if($obj->comment_srl) + { + $point = $module_config['blamed_comment']; + if(strlen($point) == 0 && !is_int($point)) $point = $config->blamed_comment; + } + else + { + $point = $module_config['blamed']; + if(strlen($point) == 0 && !is_int($point)) $point = $config->blamed; + } } + if(!$point) return new Object(); // Increase the point $cur_point += $point;