Fix error when highlighting and toping an alone thread.
This commit is contained in:
parent
7ab272005a
commit
0d136c967a
@ -657,8 +657,10 @@
|
||||
$.addClass(root, result["class"]);
|
||||
if (isOP && result.top && !g.REPLY) {
|
||||
thisThread = root.parentNode;
|
||||
if (firstThread = $('div[class="postContainer opContainer"]').parentNode) {
|
||||
$.before(firstThread, [thisThread, thisThread.nextElementSibling]);
|
||||
if (firstThread = $('div[class="postContainer opContainer"]')) {
|
||||
if (firstThread !== root) {
|
||||
$.before(firstThread.parentNode, [thisThread, thisThread.nextElementSibling]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -531,8 +531,9 @@ Filter =
|
||||
# Put the highlighted OPs' thread on top of the board page...
|
||||
thisThread = root.parentNode
|
||||
# ...before the first non highlighted thread.
|
||||
if firstThread = $('div[class="postContainer opContainer"]').parentNode
|
||||
$.before firstThread, [thisThread, thisThread.nextElementSibling]
|
||||
if firstThread = $ 'div[class="postContainer opContainer"]'
|
||||
unless firstThread is root
|
||||
$.before firstThread.parentNode, [thisThread, thisThread.nextElementSibling]
|
||||
|
||||
name: (post) ->
|
||||
$('.name', post.el).textContent
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user