| @@ 1103-1112 (lines=10) @@ | ||
| 1100 | $oDB->begin(); |
|
| 1101 | ||
| 1102 | // update the number of votes |
|
| 1103 | if($point < 0) |
|
| 1104 | { |
|
| 1105 | $args->blamed_count = $oComment->get('blamed_count') + $point; |
|
| 1106 | $output = executeQuery('comment.updateBlamedCount', $args); |
|
| 1107 | } |
|
| 1108 | else |
|
| 1109 | { |
|
| 1110 | $args->voted_count = $oComment->get('voted_count') + $point; |
|
| 1111 | $output = executeQuery('comment.updateVotedCount', $args); |
|
| 1112 | } |
|
| 1113 | ||
| 1114 | // leave logs |
|
| 1115 | $args->point = $point; |
|
| @@ 1124-1133 (lines=10) @@ | ||
| 1121 | $oDB->begin(); |
|
| 1122 | ||
| 1123 | // Update the voted count |
|
| 1124 | if($point < 0) |
|
| 1125 | { |
|
| 1126 | $args->blamed_count = $oDocument->get('blamed_count') + $point; |
|
| 1127 | $output = executeQuery('document.updateBlamedCount', $args); |
|
| 1128 | } |
|
| 1129 | else |
|
| 1130 | { |
|
| 1131 | $args->voted_count = $oDocument->get('voted_count') + $point; |
|
| 1132 | $output = executeQuery('document.updateVotedCount', $args); |
|
| 1133 | } |
|
| 1134 | if(!$output->toBool()) return $output; |
|
| 1135 | // Leave logs |
|
| 1136 | $args->point = $point; |
|