fix(editor): Resolve $vars and $secrets in expressions in credentials fields (#9289)

This commit is contained in:
Iván Ovejero
2024-05-03 14:39:31 +02:00
committed by GitHub
parent 6ab3781570
commit d92f994913
4 changed files with 55 additions and 22 deletions

View File

@@ -202,14 +202,18 @@ export default defineComponent({
? this.modelValue.value
: this.modelValue;
if (!this.activeNode || !this.isValueExpression || typeof value !== 'string') {
if (
!this.isForCredential &&
(!this.activeNode || !this.isValueExpression || typeof value !== 'string')
) {
return { ok: false, error: new Error() };
}
try {
let opts;
let opts = { isForCredential: this.isForCredential };
if (this.ndvStore.isInputParentOfActiveNode) {
opts = {
...opts,
targetItem: this.targetItem ?? undefined,
inputNodeName: this.ndvStore.ndvInputNodeName,
inputRunIndex: this.ndvStore.ndvInputRunIndex,