"error", "no_error",
"moved", "size", "md5", "real_title",
"last_tested", "last_modified", "test_time",
- "icon", "icon_href",
+ "icon", "icon_href", "charset",
):
if hasattr(new_b, attr):
setattr(bookmark, attr, getattr(new_b, attr))
content_stripped = content.strip()
if content_stripped and is_html:
parser = parse_html(content_stripped, charset, self.log)
+ if charset:
+ bookmark.charset = charset
+ elif parser and parser.meta_charset:
+ bookmark.charset = parser.meta_charset
if parser:
bookmark.real_title = parser.title
icon = parser.icon
LastModified: %s
IconURI: %s
Icon: %s
+ Charset: %s
""" % (
bookmark.href, getattr(bookmark, 'real_title', ''),
strftime(bookmark.last_modified), bookmark.icon_href,
- bookmark.icon))
+ bookmark.icon, bookmark.charset))
robot.stop()
log.close()