gilding: Fix bug where thingupdater counts were incremented.

The value supplied by the inlined thingupdater data is the current
count and should not be incremented by gildComment.
This commit is contained in:
Max Goodman
2012-11-20 16:32:52 -08:00
parent e537c3e247
commit 763e824a48

View File

@@ -75,8 +75,10 @@ r.gold = {
var tagline = comment.children('.entry').find('p.tagline'),
icon = tagline.find('.gilded-comment-icon')
gilding_count = gilding_count || icon.data('count') || 0
gilding_count++
if (gilding_count == null) {
gilding_count = icon.data('count') || 0
gilding_count++
}
comment.addClass('gilded user-gilded')
if (!icon.length) {