From a6dd530445b282c35407f40bf83160bb6cf8dfb3 Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Thu, 11 Oct 2007 15:56:22 +0000 Subject: [PATCH] Ignore case for comparison. git-svn-id: file:///home/phd/archive/SVN/bookmarks_db/trunk@90 fdd5c36f-1aea-0310-aeeb-c58d7e2b6c23 --- Robots/parse_html.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Robots/parse_html.py b/Robots/parse_html.py index 90b777b..c6a72f6 100755 --- a/Robots/parse_html.py +++ b/Robots/parse_html.py @@ -71,15 +71,13 @@ class HTMLParser(_HTMLParser): for attrname, value in attrs: if value: value = value.strip().lower() - if (attrname == 'rel') and (value in ('icon', 'shortcut icon')): + if (attrname == 'rel') and (value.lower() in ('icon', 'shortcut icon')): has_icon = True elif attrname == 'href': href = value if has_icon: self.icon = href - else: - self.icon = None import re -- 2.39.5