commit | c049fca0da0b81b04060d52443af493afa560ee8 | [log] [tgz] |
---|---|---|
author | Florent Xicluna <florent.xicluna@gmail.com> | Sat Jul 31 08:56:55 2010 +0000 |
committer | Florent Xicluna <florent.xicluna@gmail.com> | Sat Jul 31 08:56:55 2010 +0000 |
tree | 6ed83d033f4f76f006d086848126e2526acb151f | |
parent | 62069d3ce743c6f5f91ef3700d6bc2cc69172359 [diff] [blame] |
Fix an oversight in r83294. unquote() should reject bytes. Issue #9301.
diff --git a/Lib/urllib/parse.py b/Lib/urllib/parse.py index a9fa26a..133b9d9 100644 --- a/Lib/urllib/parse.py +++ b/Lib/urllib/parse.py
@@ -338,7 +338,7 @@ unquote('abc%20def') -> 'abc def'. """ - if string in (b'', ''): + if string == '': return string res = string.split('%') if len(res) == 1: