Skip to content

Commit 49b2acb

Browse files
committed
remove redundant check
1 parent 668e201 commit 49b2acb

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

lib/internal/repl/await.js

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -110,11 +110,9 @@ function processTopLevelAwait(src) {
110110
// Convert keyword parse errors on await into their original errors when
111111
// possible.
112112
if (errPos === awaitPos + 6 &&
113-
src.slice(errPos - 6, errPos - 1) === 'await' &&
114113
e.message.includes('Expecting Unicode escape sequence'))
115114
return null;
116115
if (errPos === awaitPos + 7 &&
117-
src.slice(errPos - 7, errPos - 2) === 'await' &&
118116
e.message.includes('Unexpected token'))
119117
return null;
120118
const { line, column } = e.loc;

0 commit comments

Comments
 (0)