fix(core): Add empty credential value marker to show empty pw field (#6532)

add empty credential value marker to show empty pw field
This commit is contained in:
Michael Auerswald
2023-06-23 18:23:28 +02:00
committed by GitHub
parent d9ed0b31b5
commit 9294e2da3c
3 changed files with 22 additions and 6 deletions

View File

@@ -367,7 +367,7 @@ import type {
EditorType,
CodeNodeEditorLanguage,
} from 'n8n-workflow';
import { NodeHelpers } from 'n8n-workflow';
import { NodeHelpers, CREDENTIAL_EMPTY_VALUE } from 'n8n-workflow';
import CredentialsSelect from '@/components/CredentialsSelect.vue';
import ExpressionEdit from '@/components/ExpressionEdit.vue';
@@ -607,6 +607,11 @@ export default defineComponent({
return this.$locale.baseText('parameterInput.loadingOptions');
}
// if the value is marked as empty return empty string, to prevent displaying the asterisks
if (this.value === CREDENTIAL_EMPTY_VALUE) {
return '';
}
let returnValue;
if (this.isValueExpression === false) {
returnValue = this.isResourceLocatorParameter