explicit unicode strings in the README example, fixes #51

This commit is contained in:
Mahmoud Hashemi 2017-11-18 09:55:01 -08:00
parent e6836c6f09
commit 272d8012c9
1 changed files with 4 additions and 4 deletions

View File

@ -32,10 +32,10 @@ Then, hyperlink away!
```python
from hyperlink import URL
url = URL.from_text('http://github.com/mahmoud/hyperlink?utm_source=README')
utm_source = url.get('utm_source')
better_url = url.replace(scheme='https')
user_url = better_url.click('..')
url = URL.from_text(u'http://github.com/mahmoud/hyperlink?utm_source=README')
utm_source = url.get(u'utm_source')
better_url = url.replace(scheme=u'https')
user_url = better_url.click(u'..')
```
See the full API docs on [Read the Docs][docs].