Skip to content
Snippets Groups Projects
Commit 4ebe06e6 authored by Robin Leber's avatar Robin Leber
Browse files

FIX: correct topic creation

parent aefd5f57
No related branches found
No related tags found
No related merge requests found
......@@ -63,7 +63,11 @@ export const handlePipeBinding = (pipeMapping, editor) => {
let position = line.from;
let pipeNameUserGiven = pipe.pipeName;
let pipeNameDeklaration = makeValidConstName(pipeNameUserGiven);
let insertCode = `\t\tconst ${pipeNameDeklaration} = "${pipeNameUserGiven}";\n\t\tawait channel.assert${pipe.pipeType}(${pipeNameDeklaration}, {\n\t\t\tdurable: false\n\t\t});\n`;
let insertCode = `\t\tconst ${pipeNameDeklaration} = "${pipeNameUserGiven}";\n\t\tchannel.assert${
pipe.pipeType === "Queue" ? "Queue" : "Exchange"
}(${pipeNameDeklaration}, ${
pipe.pipeType === "Topic" ? `"topic", ` : ""
}{\n\t\t\tdurable: false\n\t\t});\n`;
let transaction = editor.state.update({
changes: {
from: position,
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment