Delete entire boards from DataBoards when cleaning it gives us a 404.
This would happen when a board gets deleted, like /s4s/ hopefully one day.
This commit is contained in:
parent
8bae973931
commit
a0c4d86dee
@ -65,6 +65,10 @@ class DataBoard
|
||||
$.set @key, @data
|
||||
ajaxClean: (boardID) ->
|
||||
$.ajax "//api.4chan.org/#{boardID}/threads.json", onload: (e) =>
|
||||
if e.target.status is 404
|
||||
# Deleted board.
|
||||
@delete boardID
|
||||
else if e.target.status is 200
|
||||
board = @data.boards[boardID]
|
||||
threads = {}
|
||||
for page in JSON.parse e.target.response
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user