mirror of
https://github.com/Infisical/infisical.git
synced 2025-03-29 22:02:57 +00:00
fix: hide envs without read permission in secret main page nav header dropdown
This commit is contained in:
@ -344,7 +344,15 @@ export const SecretMainPage = () => {
|
||||
<NavHeader
|
||||
pageName={t("dashboard.title")}
|
||||
currentEnv={environment}
|
||||
userAvailableEnvs={currentWorkspace?.environments}
|
||||
userAvailableEnvs={currentWorkspace?.environments.filter(({ slug }) =>
|
||||
permission.can(
|
||||
ProjectPermissionActions.Read,
|
||||
subject(ProjectPermissionSub.Secrets, {
|
||||
environment: slug,
|
||||
secretPath
|
||||
})
|
||||
)
|
||||
)}
|
||||
isFolderMode
|
||||
secretPath={secretPath}
|
||||
isProjectRelated
|
||||
|
Reference in New Issue
Block a user