Skip to content

Commit 841c0af

Browse files
committed
fix: robust pipe detection for branching enhancement paths
1 parent fbe9747 commit 841c0af

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

js/detail.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -255,7 +255,7 @@
255255
'</div>';
256256
};
257257

258-
var rawPaths = rec.split('|').map(function (s) { return s.trim(); }).filter(Boolean);
258+
var rawPaths = rec.split(/[|]/).map(function (s) { return s.trim(); }).filter(Boolean);
259259
var pathHTML = '<div class="enhancement-tree">';
260260

261261
if (rawPaths.length > 1) {
@@ -288,8 +288,8 @@
288288
});
289289
pathHTML += '</div>';
290290
} else {
291-
// LINEAR LOGIC (original, cleaned up)
292-
var steps = rec.split(/[>;]/).map(function (s) { return s.trim(); }).filter(Boolean);
291+
// LINEAR LOGIC
292+
var steps = rec.split(/[>;|]/).map(function (s) { return s.trim(); }).filter(Boolean);
293293
steps.forEach(function (stepName, idx) {
294294
var rank = "up";
295295
if (idx === 0) rank = "base";

0 commit comments

Comments
 (0)