mirror of
https://github.com/schollz/cowyo.git
synced 2023-08-10 21:13:00 +03:00
Allow raw to get locked copy
This commit is contained in:
parent
3f70a86d65
commit
685117ffd3
@ -76,7 +76,8 @@ func handlePageRequest(c *gin.Context) {
|
|||||||
p := Open(page)
|
p := Open(page)
|
||||||
|
|
||||||
// Disallow anything but viewing locked/encrypted pages
|
// Disallow anything but viewing locked/encrypted pages
|
||||||
if (p.IsEncrypted || p.IsLocked) && command[0:2] != "/v" {
|
if (p.IsEncrypted || p.IsLocked) &&
|
||||||
|
(command[0:2] != "/v" && command[0:2] != "/r") {
|
||||||
c.Redirect(302, "/"+page+"/view")
|
c.Redirect(302, "/"+page+"/view")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user