home
·
contact
·
privacy
projects
/
plomlombot-irc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
f093ae1
)
Fix buggy HTMLParser.
author
Christian Heller
<c.heller@plomlompom.de>
Tue, 19 Jan 2016 00:36:15 +0000
(
01:36
+0100)
committer
Christian Heller
<c.heller@plomlompom.de>
Tue, 19 Jan 2016 00:36:15 +0000
(
01:36
+0100)
plomlombot.py
patch
|
blob
|
history
diff --git
a/plomlombot.py
b/plomlombot.py
index f34d97a821378c5e092cf064a78a2137d82350c7..9e9d0a44ce21bc1d07204dcb9780c54ac1b31d0e 100755
(executable)
--- a/
plomlombot.py
+++ b/
plomlombot.py
@@
-22,11
+22,12
@@
NICKNAME = USERNAME
class HTMLParser(html.parser.HTMLParser):
def __init__(self, html, tag):
super().__init__()
+ self._tag_to_check = tag
self._tag = ""
self.data = ""
self.feed(html)
def handle_starttag(self, tag, attrs):
- if self.data == "":
+ if self.data == ""
and tag == self._tag_to_check
:
self._tag = tag
def handle_endtag(self, tag):
self._tag = ""