From 09547b4c8d9c6a62665622ec75e9c2e2c6b3be23 Mon Sep 17 00:00:00 2001 From: Good Wood Date: Tue, 20 May 2025 14:41:10 +0800 Subject: [PATCH] fix: fix page broken for undefined permission (#19972) --- web/app/components/plugins/permission-setting-modal/modal.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/web/app/components/plugins/permission-setting-modal/modal.tsx b/web/app/components/plugins/permission-setting-modal/modal.tsx index f56c079818..6fd4d8c2dc 100644 --- a/web/app/components/plugins/permission-setting-modal/modal.tsx +++ b/web/app/components/plugins/permission-setting-modal/modal.tsx @@ -49,8 +49,8 @@ const PluginSettingModal: FC = ({
{[ - { title: t(`${i18nPrefix}.whoCanInstall`), key: 'install_permission', value: tempPrivilege.install_permission }, - { title: t(`${i18nPrefix}.whoCanDebug`), key: 'debug_permission', value: tempPrivilege.debug_permission }, + { title: t(`${i18nPrefix}.whoCanInstall`), key: 'install_permission', value: tempPrivilege?.install_permission || PermissionType.noOne }, + { title: t(`${i18nPrefix}.whoCanDebug`), key: 'debug_permission', value: tempPrivilege?.debug_permission || PermissionType.noOne }, ].map(({ title, key, value }) => (