mirror of
https://github.com/zotero/zotero.git
synced 2026-10-10 03:28:10 +00:00
Run JavaScript: Improve await regex (#2083)
Tests: https://regex101.com/r/eQYCIp/1
This commit is contained in:
parent
57596d72e7
commit
381b2753ce
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
Reference in a new issue