diff --git a/4chan_x.js b/4chan_x.js
index 79a872148..9294ed71b 100644
--- a/4chan_x.js
+++ b/4chan_x.js
@@ -1971,14 +1971,13 @@
threadStats = {
init: function() {
var html;
- html = "
Replies: 0 Images:
";
+ threadStats.replies = 0;
+ threadStats.images = $('.op img[md5]') ? 1 : 0;
+ html = "Replies: " + threadStats.replies + " Images: " + threadStats.images + "
";
$.append(d.body, ui.dialog('stats', {
bottom: '0px',
left: '0px'
}, html));
- threadStats.replies = 0;
- threadStats.images = $('.op img[md5]') ? 1 : 0;
- $('#icount').textContent = threadStats.images;
return g.callbacks.push(threadStats.node);
},
node: function(root) {
diff --git a/script.coffee b/script.coffee
index b7bb4eaac..6a39a79c7 100644
--- a/script.coffee
+++ b/script.coffee
@@ -1547,11 +1547,10 @@ reportButton =
threadStats =
init: ->
- html = "Replies: 0 Images:
"
- $.append d.body, (ui.dialog 'stats', bottom: '0px', left: '0px', html)
threadStats.replies = 0
threadStats.images = if $ '.op img[md5]' then 1 else 0
- $('#icount').textContent = threadStats.images
+ html = "Replies: #{threadStats.replies} Images: #{threadStats.images}
"
+ $.append d.body, (ui.dialog 'stats', bottom: '0px', left: '0px', html)
g.callbacks.push threadStats.node
node: (root) ->
return if root.className