mirror of
https://github.com/makeplane/plane.git
synced 2026-07-12 13:29:56 +02:00
fix: auth for access change and delete
This commit is contained in:
@@ -84,7 +84,7 @@ export const PageActions: React.FC<Props> = observer((props) => {
|
||||
action: pageOperations.toggleAccess,
|
||||
title: access === EPageAccess.PUBLIC ? "Make private" : "Make public",
|
||||
icon: access === EPageAccess.PUBLIC ? Lock : Globe2,
|
||||
shouldRender: canCurrentUserChangeAccess,
|
||||
shouldRender: canCurrentUserChangeAccess && !archived_at,
|
||||
},
|
||||
{
|
||||
key: "open-in-new-tab",
|
||||
@@ -119,7 +119,7 @@ export const PageActions: React.FC<Props> = observer((props) => {
|
||||
action: () => setDeletePageModal(true),
|
||||
title: "Delete",
|
||||
icon: Trash2,
|
||||
shouldRender: canCurrentUserDeletePage,
|
||||
shouldRender: canCurrentUserDeletePage && !!archived_at,
|
||||
},
|
||||
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user