Revert "Revert "Update auth hooks to use new endpoint and add perms checking"" (#29894)

Revert "Revert "Update auth hooks to use new endpoint and add perms checking"…"

This reverts commit a2a94d1f74.
This commit is contained in:
Joshen Lim
2024-10-16 09:13:07 +08:00
committed by GitHub
parent e95b0cb277
commit 34f02f344b
9 changed files with 450 additions and 158 deletions

View File

@@ -24,8 +24,8 @@ const EdgeFunctionSecrets = () => {
const [showCreateSecret, setShowCreateSecret] = useState(false)
const [selectedSecret, setSelectedSecret] = useState<ProjectSecret>()
const canReadSecrets = useCheckPermissions(PermissionAction.FUNCTIONS_READ, '*')
const canUpdateSecrets = useCheckPermissions(PermissionAction.FUNCTIONS_WRITE, '*')
const canReadSecrets = useCheckPermissions(PermissionAction.SECRETS_READ, '*')
const canUpdateSecrets = useCheckPermissions(PermissionAction.SECRETS_WRITE, '*')
const { data, error, isLoading, isSuccess, isError } = useSecretsQuery({
projectRef: projectRef,