mirror of
https://github.com/9001/copyparty.git
synced 2025-11-24 07:23:22 -07:00
fix textviewer with g permission; closes #927
textfiles can also be viewed with `foo.txt?v` for less jank
This commit is contained in:
parent
b4fda5f1d6
commit
dbb78705f7
|
|
@ -6567,6 +6567,9 @@ class HttpCli(object):
|
|||
elif is_dir and not self.can_read:
|
||||
if use_dirkey:
|
||||
is_dk = True
|
||||
elif self.can_get and "doc" in self.uparam:
|
||||
zs = vjoin(self.vpath, self.uparam["doc"]) + "?v"
|
||||
return self.redirect(zs, flavor="redirecting to", use302=True)
|
||||
elif not self.can_write:
|
||||
return self.tx_404(True)
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue