🛂(back) restrict document's duplicate action to authenticated users
The duplicate was also able for anonynous user if they can read it. We have to restrict it to at least reader authenticated otherwise no access will be created on the duplicated document.
This commit is contained in:
committed by
Anthony LC
parent
fc1678d0c2
commit
e82e6a1fcf
@@ -842,7 +842,7 @@ class Document(MP_Node, BaseModel):
|
||||
"cors_proxy": can_get,
|
||||
"descendants": can_get,
|
||||
"destroy": is_owner,
|
||||
"duplicate": can_get,
|
||||
"duplicate": can_get and user.is_authenticated,
|
||||
"favorite": can_get and user.is_authenticated,
|
||||
"link_configuration": is_owner_or_admin,
|
||||
"invite_owner": is_owner,
|
||||
|
||||
Reference in New Issue
Block a user