diff --git a/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue b/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue index 856f0c9315..ba3eb19ff0 100644 --- a/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue +++ b/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue @@ -280,8 +280,7 @@ const requiredPropertiesFilled = computed(() => { const credentialPermissions = computed(() => { return getResourcePermissions( - ((credentialId.value ? currentCredential.value : credentialData.value) as ICredentialsResponse) - ?.scopes, + (currentCredential.value as ICredentialsResponse)?.scopes ?? homeProject.value?.scopes, ).credential; }); @@ -341,11 +340,8 @@ onMounted(async () => { credentialTypeName: defaultCredentialTypeName.value, }); - const scopes = homeProject.value?.scopes ?? []; - credentialData.value = { ...credentialData.value, - scopes, ...(homeProject.value ? { homeProject: homeProject.value } : {}), }; } else {