(path)
| 462 | } |
| 463 | |
| 464 | function normalizePath(path) { |
| 465 | let result = String(path || "").replace(/\\/g, "/"); |
| 466 | while (result.length > 1 && result.endsWith("/")) { |
| 467 | const prefix = result.slice(0, -1); |
| 468 | if (/^[a-z]+:\/{0,2}$/i.test(prefix)) break; |
| 469 | result = prefix; |
| 470 | } |
| 471 | return result; |
| 472 | } |
| 473 | |
| 474 | function pathsAreSame(a, b) { |
| 475 | if (!a || !b) return false; |
no test coverage detected