Run JavaScript: Improve await
regex (#2083)
Tests: https://regex101.com/r/eQYCIp/1
This commit is contained in:
parent
864b135da4
commit
5359db39d0
1 changed files with 1 additions and 1 deletions
|
@ -45,7 +45,7 @@ function handleInput() { // eslint-disable-line no-unused-vars
|
|||
}
|
||||
var code = codeEditor.getSession().getValue();
|
||||
// If `await` is used, switch to async mode
|
||||
if (/(^|[^=([]\s*)await\s/m.test(code)) {
|
||||
if (/(^|\W)await\s/m.test(code)) {
|
||||
checkbox.checked = true;
|
||||
update();
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue