Skip to content

Commit

Permalink
add slash
Browse files Browse the repository at this point in the history
  • Loading branch information
jph00 committed Nov 16, 2020
1 parent d5e0e37 commit 0ff4a33
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion fastcore/xtras.py
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ def urlquote(url):
"Update url's path with `urllib.parse.quote`"
subdelims = "!$&'()*+,;="
gendelims = ":?#[]@"
safe = subdelims+gendelims+"%"
safe = subdelims+gendelims+"%/"
p = list(urlparse(url))
p[2] = urllib.parse.quote(p[2], safe=safe)
for i in range(3,6): p[i] = urllib.parse.quote(p[i], safe=safe)
Expand Down
8 changes: 4 additions & 4 deletions nbs/03_xtras.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@
{
"data": {
"text/plain": [
"['e', 'c', 'h', 'a', 'f', 'g', 'b', 'd']"
"['e', 'g', 'a', 'd', 'c', 'b', 'f', 'h']"
]
},
"execution_count": null,
Expand Down Expand Up @@ -1168,7 +1168,7 @@
" \"Update url's path with `urllib.parse.quote`\"\n",
" subdelims = \"!$&'()*+,;=\"\n",
" gendelims = \":?#[]@\"\n",
" safe = subdelims+gendelims+\"%\"\n",
" safe = subdelims+gendelims+\"%/\"\n",
" p = list(urlparse(url))\n",
" p[2] = urllib.parse.quote(p[2], safe=safe)\n",
" for i in range(3,6): p[i] = urllib.parse.quote(p[i], safe=safe)\n",
Expand All @@ -1183,7 +1183,7 @@
{
"data": {
"text/plain": [
"'https://github.com/%2Ffastai%2Ffastai%2Fcompare%2Fmaster@%7B1.day.ago%7D%E2%80%A6master'"
"'https://github.com/fastai/fastai/compare/master@%7B1.day.ago%7D%E2%80%A6master'"
]
},
"execution_count": null,
Expand All @@ -1203,7 +1203,7 @@
{
"data": {
"text/plain": [
"'https://www.google.com/%2Fsearch?q=%E4%BD%A0%E5%A5%BD'"
"'https://www.google.com/search?q=%E4%BD%A0%E5%A5%BD'"
]
},
"execution_count": null,
Expand Down

0 comments on commit 0ff4a33

Please # to comment.