Fixed an wrong example of the doc

This commit is contained in:
CORDEA
2016-03-02 20:55:02 +09:00
parent 180a4b7657
commit f77bc7d93a

View File

@@ -255,13 +255,13 @@ proc `/`*(x: Uri, path: string): Uri =
## Examples:
##
## .. code-block::
## let foo = parseUri("http://example.com/foo/bar") / parseUri("/baz")
## let foo = parseUri("http://example.com/foo/bar") / "/baz"
## assert foo.path == "/foo/bar/baz"
##
## let bar = parseUri("http://example.com/foo/bar") / parseUri("baz")
## let bar = parseUri("http://example.com/foo/bar") / "baz"
## assert bar.path == "/foo/bar/baz"
##
## let bar = parseUri("http://example.com/foo/bar/") / parseUri("baz")
## let bar = parseUri("http://example.com/foo/bar/") / "baz"
## assert bar.path == "/foo/bar/baz"
result = x
if result.path[result.path.len-1] == '/':