Dolda2000 GitWeb
/
wrw.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
08a4b74
)
Changed some whitespace usage.
author
Fredrik Tolf
<fredrik@dolda2000.com>
Sun, 5 Aug 2012 16:08:59 +0000
(18:08 +0200)
committer
Fredrik Tolf
<fredrik@dolda2000.com>
Sun, 5 Aug 2012 16:08:59 +0000
(18:08 +0200)
wrw/proto.py
patch
|
blob
|
blame
|
history
diff --git
a/wrw/proto.py
b/wrw/proto.py
index
aed5c4e
..
3d8b96e
100644
(file)
--- a/
wrw/proto.py
+++ b/
wrw/proto.py
@@
-113,7
+113,7
@@
def parseurl(url):
local = local[:q]
return proto, host, local, query
local = local[:q]
return proto, host, local, query
-def consurl(proto, host, local, query
=
""):
+def consurl(proto, host, local, query
=
""):
if len(local) < 1 and local[0] != '/':
raise urlerror("Local part of URL must begin with a slash")
ret = "%s://%s%s" % (proto, host, local)
if len(local) < 1 and local[0] != '/':
raise urlerror("Local part of URL must begin with a slash")
ret = "%s://%s%s" % (proto, host, local)
@@
-142,7
+142,7
@@
def requrl(req):
raise Exception("Malformed local part when reconstructing URL")
return "%s://%s%s" % (proto, host, req.uri)
raise Exception("Malformed local part when reconstructing URL")
return "%s://%s%s" % (proto, host, req.uri)
-def parstring(pars
=
{}, **augment):
+def parstring(pars
=
{}, **augment):
buf = ""
for key in pars:
if key in augment:
buf = ""
for key in pars:
if key in augment:
@@
-157,7
+157,7
@@
def parstring(pars = {}, **augment):
buf += urlq(key) + "=" + urlq(str(augment[key]))
return buf
buf += urlq(key) + "=" + urlq(str(augment[key]))
return buf
-def parurl(url, pars
=
{}, **augment):
+def parurl(url, pars
=
{}, **augment):
qs = parstring(pars, **augment)
if qs != "":
return url + "?" + qs
qs = parstring(pars, **augment)
if qs != "":
return url + "?" + qs