Skip to content

Commit 5a01980

Browse files
committed
Be carefull about the regex result
1 parent 1b179e8 commit 5a01980

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

‎packages/devtools-vite/src/utils.ts‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,10 @@ export const handleDevToolsViteRequest = (
1616
return
1717
}
1818
const parts = source.match(/^(.*?):(\d+):(\d+)$/)
19+
if (!parts) {
20+
return
21+
}
22+
1923
const [, file, line, column] = parts
2024

2125
cb({

0 commit comments

Comments
 (0)