webpipe-js 2.0.65 → 2.0.66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -2083,16 +2083,10 @@ function formatPipelineStep(step, indent = " ", isLastStep = false) {
2083
2083
  } else if (step.kind === "Dispatch") {
2084
2084
  const lines = [`${indent}|> dispatch`];
2085
2085
  step.branches.forEach((branch) => {
2086
- if (branch.pipeline.steps.length === 1) {
2087
- const inlineStep = formatPipelineStep(branch.pipeline.steps[0], indent + " ");
2088
- const stepContent = inlineStep.substring((indent + " ").length);
2089
- lines.push(`${indent} case ${formatTagExpr(branch.condition)}: ${stepContent}`);
2090
- } else {
2091
- lines.push(`${indent} case ${formatTagExpr(branch.condition)}:`);
2092
- branch.pipeline.steps.forEach((branchStep) => {
2093
- lines.push(formatPipelineStep(branchStep, indent + " "));
2094
- });
2095
- }
2086
+ lines.push(`${indent} case ${formatTagExpr(branch.condition)}:`);
2087
+ branch.pipeline.steps.forEach((branchStep) => {
2088
+ lines.push(formatPipelineStep(branchStep, indent + " "));
2089
+ });
2096
2090
  });
2097
2091
  if (step.default) {
2098
2092
  lines.push(`${indent} default:`);
package/dist/index.mjs CHANGED
@@ -2029,16 +2029,10 @@ function formatPipelineStep(step, indent = " ", isLastStep = false) {
2029
2029
  } else if (step.kind === "Dispatch") {
2030
2030
  const lines = [`${indent}|> dispatch`];
2031
2031
  step.branches.forEach((branch) => {
2032
- if (branch.pipeline.steps.length === 1) {
2033
- const inlineStep = formatPipelineStep(branch.pipeline.steps[0], indent + " ");
2034
- const stepContent = inlineStep.substring((indent + " ").length);
2035
- lines.push(`${indent} case ${formatTagExpr(branch.condition)}: ${stepContent}`);
2036
- } else {
2037
- lines.push(`${indent} case ${formatTagExpr(branch.condition)}:`);
2038
- branch.pipeline.steps.forEach((branchStep) => {
2039
- lines.push(formatPipelineStep(branchStep, indent + " "));
2040
- });
2041
- }
2032
+ lines.push(`${indent} case ${formatTagExpr(branch.condition)}:`);
2033
+ branch.pipeline.steps.forEach((branchStep) => {
2034
+ lines.push(formatPipelineStep(branchStep, indent + " "));
2035
+ });
2042
2036
  });
2043
2037
  if (step.default) {
2044
2038
  lines.push(`${indent} default:`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "webpipe-js",
3
- "version": "2.0.65",
3
+ "version": "2.0.66",
4
4
  "description": "Web Pipe parser",
5
5
  "license": "ISC",
6
6
  "author": "William Cotton",