mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 04:34:06 -08:00
fix(editor): Credentials scopes and n8n scopes mix up (#10930)
This commit is contained in:
parent
6de4dfff87
commit
e069608022
|
@ -280,8 +280,7 @@ const requiredPropertiesFilled = computed(() => {
|
||||||
|
|
||||||
const credentialPermissions = computed(() => {
|
const credentialPermissions = computed(() => {
|
||||||
return getResourcePermissions(
|
return getResourcePermissions(
|
||||||
((credentialId.value ? currentCredential.value : credentialData.value) as ICredentialsResponse)
|
(currentCredential.value as ICredentialsResponse)?.scopes ?? homeProject.value?.scopes,
|
||||||
?.scopes,
|
|
||||||
).credential;
|
).credential;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -341,11 +340,8 @@ onMounted(async () => {
|
||||||
credentialTypeName: defaultCredentialTypeName.value,
|
credentialTypeName: defaultCredentialTypeName.value,
|
||||||
});
|
});
|
||||||
|
|
||||||
const scopes = homeProject.value?.scopes ?? [];
|
|
||||||
|
|
||||||
credentialData.value = {
|
credentialData.value = {
|
||||||
...credentialData.value,
|
...credentialData.value,
|
||||||
scopes,
|
|
||||||
...(homeProject.value ? { homeProject: homeProject.value } : {}),
|
...(homeProject.value ? { homeProject: homeProject.value } : {}),
|
||||||
};
|
};
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue