mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
Read-only privelege for anonymous access
This commit is contained in:
parent
06966f67db
commit
fc202439ab
1 changed files with 3 additions and 1 deletions
|
@ -25,9 +25,11 @@ module.exports = AuthorizationManager =
|
|||
return callback null, PrivilegeLevels.READ_ONLY, true
|
||||
else if project.publicAccesLevel == PublicAccessLevels.READ_AND_WRITE
|
||||
return callback null, PrivilegeLevels.READ_AND_WRITE, true
|
||||
else if project.publicAccesLevel == PublicAccessLevels.TOKEN_BASED
|
||||
return callback null, PrivilegeLevels.READ_ONLY, false
|
||||
else
|
||||
return callback null, PrivilegeLevels.NONE, false
|
||||
|
||||
|
||||
if !user_id?
|
||||
getPublicAccessLevel()
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue