mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-11 21:07:28 -08:00
🐛 Rework expression for renaming node for dotted expressions (#2380)
This commit is contained in:
parent
ba8c922604
commit
c73a5f76dc
|
@ -415,8 +415,7 @@ export class Workflow {
|
||||||
const currentNameEscaped = currentName.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
const currentNameEscaped = currentName.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
|
||||||
|
|
||||||
parameterValue = parameterValue.replace(
|
parameterValue = parameterValue.replace(
|
||||||
// eslint-disable-next-line no-useless-escape
|
new RegExp(`(\\$node(\\.|\\["|\\['))${currentNameEscaped}((\\.|"\\]|'\\]))`, 'g'),
|
||||||
new RegExp(`(\\$node(\.|\\["|\\[\'))${currentNameEscaped}((\s/g|"\\]|\'\\]))`, 'g'),
|
|
||||||
`$1${newName}$3`,
|
`$1${newName}$3`,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue