diff options
| author | czaks <marcin@6irc.net> | 2013-07-26 22:34:06 -0400 |
|---|---|---|
| committer | Michael Foster <savetheinternet@tinyboard.org> | 2013-07-27 00:28:43 -0400 |
| commit | 6bf217941a3342cdcf7768ab5269f7d35b050984 (patch) | |
| tree | fa093303ae3bf93abc2bc3d42e236124d43eabc1 | |
| parent | c0a45ba1237fd54c0d5050d3a70abdea022ff6c3 (diff) | |
expand.js: fix a weird bug - thread expand not always worked due to post being loaded in DOM, but not put in a right place in a thread, or so, so check if it has been loaded in a thread instead of if it exists in DOM
| -rw-r--r-- | js/expand.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/js/expand.js b/js/expand.js index 05aece95..d0b4583c 100644 --- a/js/expand.js +++ b/js/expand.js @@ -27,7 +27,7 @@ $(document).ready(function(){ success: function(data) { var last_expanded = false; $(data).find('div.post.reply').each(function() { - if($('#' + $(this).attr('id')).length == 0) { + if(thread.find('#' + $(this).attr('id')).length == 0) { if(last_expanded) { $(this).addClass('expanded').insertAfter(last_expanded).before('<br class="expanded">'); } else { |
