Use threads.json instead catalog.json to clear threads.
This commit is contained in:
parent
3b82f1841e
commit
598d4b1143
@ -2430,10 +2430,10 @@ Misc = # super semantic
|
||||
|
||||
return if data.lastChecked > Date.now() - 12 * $.HOUR
|
||||
|
||||
$.ajax "//api.4chan.org/#{g.BOARD}/catalog.json", onload: ->
|
||||
$.ajax "//api.4chan.org/#{g.BOARD}/threads.json", onload: ->
|
||||
threads = {}
|
||||
for obj in JSON.parse @response
|
||||
for thread in obj.threads
|
||||
for page in JSON.parse @response
|
||||
for thread in page.threads
|
||||
if thread.no of data.threads
|
||||
threads[thread.no] = data.threads[thread.no]
|
||||
unless Object.keys(threads).length
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user