py3: fix regression in commit 96a8aeaaf5420dcdbb3cbeb1856a4985e8942395

Strings that contain non-ascii literal characters cannot be made into
bytestrings merely by adding b'' and must either be encoded or use
hex escapes.
This commit is contained in:
Eli Schwartz 2019-05-19 18:12:43 -04:00
parent ee97edc94d
commit 3a4acd5826
No known key found for this signature in database
GPG Key ID: CEB167EFB5722BD6

View File

@ -29,7 +29,7 @@ class insider(BasicNewsRecipe):
br['login-password'] = self.password
res = br.submit()
raw = res.read()
if b'Odhlásit se' not in raw:
if 'Odhlásit se'.encode('utf-8') not in raw:
raise ValueError('Failed to login to insider.cz'
'Check your username and password.')
return br