summaryrefslogtreecommitdiffstats
path: root/extensions/Voting/Extension.pm
diff options
context:
space:
mode:
Diffstat (limited to 'extensions/Voting/Extension.pm')
-rw-r--r--extensions/Voting/Extension.pm5
1 files changed, 4 insertions, 1 deletions
diff --git a/extensions/Voting/Extension.pm b/extensions/Voting/Extension.pm
index 6a90176ec..ead81266a 100644
--- a/extensions/Voting/Extension.pm
+++ b/extensions/Voting/Extension.pm
@@ -486,7 +486,10 @@ sub _page_user {
}
}
- $dbh->do('DELETE FROM votes WHERE vote_count <= 0');
+ if ($canedit && $bug) {
+ $dbh->do('DELETE FROM votes WHERE vote_count = 0 AND who = ?',
+ undef, $who->id);
+ }
$dbh->bz_commit_transaction();
$vars->{'canedit'} = $canedit;