Don't enable auto-posting when creating threads.
This commit is contained in:
parent
3cee0f5db2
commit
15fe688e07
@ -964,6 +964,7 @@ QR =
|
|||||||
[_, threadID, postID] = h1.nextSibling.textContent.match /thread:(\d+),no:(\d+)/
|
[_, threadID, postID] = h1.nextSibling.textContent.match /thread:(\d+),no:(\d+)/
|
||||||
postID = +postID
|
postID = +postID
|
||||||
threadID = +threadID or postID
|
threadID = +threadID or postID
|
||||||
|
isReply = threadID isnt postID
|
||||||
|
|
||||||
(QR.yourPosts.threads[threadID] or= []).push postID
|
(QR.yourPosts.threads[threadID] or= []).push postID
|
||||||
$.set "yourPosts.#{g.BOARD}", QR.yourPosts
|
$.set "yourPosts.#{g.BOARD}", QR.yourPosts
|
||||||
@ -976,14 +977,11 @@ QR =
|
|||||||
}, QR.nodes.el
|
}, QR.nodes.el
|
||||||
|
|
||||||
# Enable auto-posting if we have stuff to post, disable it otherwise.
|
# Enable auto-posting if we have stuff to post, disable it otherwise.
|
||||||
QR.cooldown.auto = QR.posts.length > 1
|
QR.cooldown.auto = QR.posts.length > 1 and isReply
|
||||||
|
|
||||||
post.rm()
|
post.rm()
|
||||||
|
|
||||||
QR.cooldown.set
|
QR.cooldown.set {req, post, isReply}
|
||||||
req: req
|
|
||||||
post: post
|
|
||||||
isReply: !!threadID
|
|
||||||
|
|
||||||
if threadID is postID # new thread
|
if threadID is postID # new thread
|
||||||
URL = "/#{g.BOARD}/res/#{threadID}"
|
URL = "/#{g.BOARD}/res/#{threadID}"
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user