From 6e1109d9a9ad949d7ac0d76d1f77b97b462246b4 Mon Sep 17 00:00:00 2001 From: Mayhem Date: Sun, 12 May 2013 23:30:16 +0200 Subject: [PATCH] Attempt to fix some obscure Redirect initialization bugs. --- src/Archive/Redirect.coffee | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/Archive/Redirect.coffee b/src/Archive/Redirect.coffee index b02253e5c..f39721cd3 100644 --- a/src/Archive/Redirect.coffee +++ b/src/Archive/Redirect.coffee @@ -5,6 +5,14 @@ Redirect = file: {} init: -> + try + Conf['archives'].length + catch err + # XXX I get obscure reports of: + # "Redirect" initialization crashed. TypeError: Cannot read property 'length' of undefined + # comming from here. + Conf['archives'] = Redirect.archives + $.delete ['archives', 'lastarchivecheck'] Redirect.update() for boardID, data of Conf['selectedArchives']