fix: Remove workflow execution credential error message when instance owner (#6116)

fix: remove execution credential error message when instance owner
This commit is contained in:
Alex Grozav
2023-05-16 13:22:53 +03:00
committed by GitHub
parent ebb3aaf61e
commit e81a96483a

View File

@@ -48,6 +48,7 @@ export const nodeHelpers = defineComponent({
useNodeTypesStore,
useSettingsStore,
useWorkflowsStore,
useUsersStore,
),
},
methods: {
@@ -355,9 +356,10 @@ export const nodeHelpers = defineComponent({
}
if (nameMatches.length === 0) {
const isInstanceOwner = this.usersStore.isInstanceOwner;
const isCredentialUsedInWorkflow =
this.workflowsStore.usedCredentials?.[selectedCredentials.id as string];
if (!isCredentialUsedInWorkflow) {
if (!isCredentialUsedInWorkflow && !isInstanceOwner) {
foundIssues[credentialTypeDescription.name] = [
this.$locale.baseText('nodeIssues.credentials.doNotExist', {
interpolate: { name: selectedCredentials.name, type: credentialDisplayName },