From 3c8873cfea75570d2e7080a7d3641218cfee24c3 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Sat, 5 Sep 2015 19:58:18 -0500 Subject: [PATCH] Fix template redlink detection. Don't block on fetching backlinks. --- tfdclerk.js | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/tfdclerk.js b/tfdclerk.js index 6a458ee..0fa7997 100644 --- a/tfdclerk.js +++ b/tfdclerk.js @@ -376,14 +376,13 @@ TFD.prototype._on_backlink_summary = function(tlinfo, ntrans, nmlinks) { }; TFD.prototype._build_close_action_entry = function(page) { - var link_id = mw.util.wikiUrlencode(page) - .replace(/%/g, "\\.").replace(/:/g, "\\:"); - var redlink = $("#" + link_id).children().first().hasClass("new"); + var redlink = this.head.nextUntil("h4").filter("ul").first() + .find("a").filter(function() { return $(this).text() == page; }) + .hasClass("new"); var tlinfo = $("