mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-02-07 20:00:20 +00:00
quote output, render GET
This commit is contained in:
parent
e894795898
commit
8268f764aa
@ -152,10 +152,12 @@ class FileNodeHandler(Resource, ReplaceMeMixin, object):
|
|||||||
if should_create_intermediate_directories(req):
|
if should_create_intermediate_directories(req):
|
||||||
raise WebError(
|
raise WebError(
|
||||||
u"Cannot create directory {}, because its "
|
u"Cannot create directory {}, because its "
|
||||||
u"parent is a file, not a directory".format(name)
|
u"parent is a file, not a directory".format(
|
||||||
|
quote_output(name, encoding='utf-8')
|
||||||
|
)
|
||||||
)
|
)
|
||||||
raise WebError(
|
raise WebError(
|
||||||
"Files have no children named {}".format(
|
u"Files have no children named {}".format(
|
||||||
quote_output(name, encoding='utf-8'),
|
quote_output(name, encoding='utf-8'),
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
@ -166,7 +166,7 @@ class FileHandler(resource.Resource, object):
|
|||||||
raise WebError("'%s' is not a file-cap" % name)
|
raise WebError("'%s' is not a file-cap" % name)
|
||||||
return filenode.FileNodeDownloadHandler(self.client, node)
|
return filenode.FileNodeDownloadHandler(self.client, node)
|
||||||
|
|
||||||
def renderHTTP(self, ctx):
|
def render_GET(self, ctx):
|
||||||
raise WebError("/file must be followed by a file-cap and a name",
|
raise WebError("/file must be followed by a file-cap and a name",
|
||||||
http.NOT_FOUND)
|
http.NOT_FOUND)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user