From 69d1d9d06d799ea551c90fbe5e9e7bc9e7fc1c01 Mon Sep 17 00:00:00 2001 From: Holger Schurig Date: Thu, 24 Jun 2010 10:24:45 +0200 Subject: [PATCH] link.py: validate link --- plugins/link.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/plugins/link.py b/plugins/link.py index 6b57e25..f7ecb2a 100644 --- a/plugins/link.py +++ b/plugins/link.py @@ -41,7 +41,11 @@ def do_link(m): break if not text: text = link - # TODO: validate link + # validate link + # TODO: validating local files still not working + if not link.startswith("http:") and not link.endswith(".html") and not link.endswith(".png"): + file = get_current_file() + warning("%s: unknown link to '%s'" % (file.rel_path, link) ) return '%s' % (link, anchor, text) -- 2.39.2