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"]);
|
$.addClass(root, result["class"]);
|
||||||
if (isOP && result.top && !g.REPLY) {
|
if (isOP && result.top && !g.REPLY) {
|
||||||
thisThread = root.parentNode;
|
thisThread = root.parentNode;
|
||||||
if (firstThread = $('div[class="postContainer opContainer"]').parentNode) {
|
if (firstThread = $('div[class="postContainer opContainer"]')) {
|
||||||
$.before(firstThread, [thisThread, thisThread.nextElementSibling]);
|
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...
|
# Put the highlighted OPs' thread on top of the board page...
|
||||||
thisThread = root.parentNode
|
thisThread = root.parentNode
|
||||||
# ...before the first non highlighted thread.
|
# ...before the first non highlighted thread.
|
||||||
if firstThread = $('div[class="postContainer opContainer"]').parentNode
|
if firstThread = $ 'div[class="postContainer opContainer"]'
|
||||||
$.before firstThread, [thisThread, thisThread.nextElementSibling]
|
unless firstThread is root
|
||||||
|
$.before firstThread.parentNode, [thisThread, thisThread.nextElementSibling]
|
||||||
|
|
||||||
name: (post) ->
|
name: (post) ->
|
||||||
$('.name', post.el).textContent
|
$('.name', post.el).textContent
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user