Skip to content

Commit

Permalink
remove warnings in tests for old python3 versions
Browse files Browse the repository at this point in the history
  • Loading branch information
boogheta committed May 31, 2021
1 parent 84a3ed8 commit e0408d7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions twitter/cmdline.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,10 +126,10 @@
}

try:
unescape = HTMLParser.HTMLParser().unescape
except AttributeError:
import html
unescape = html.unescape
except ImportError:
unescape = HTMLParser.HTMLParser().unescape

hashtagRe = re.compile(r'(?P<hashtag>#\S+)')
profileRe = re.compile(r'(?P<profile>\@\S+)')
Expand Down

0 comments on commit e0408d7

Please sign in to comment.