Skip to content

Commit

Permalink
fix JS regression
Browse files Browse the repository at this point in the history
  • Loading branch information
joshgoebel committed Oct 27, 2020
1 parent ca6c899 commit 3f06e89
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/languages/javascript.js
Expand Up @@ -182,8 +182,8 @@ export default function(hljs) {
.concat({
// we need to pair up {} inside our subst to prevent
// it from ending too early by matching another }
begin: /{/,
end: /}/,
begin: /\{/,
end: /\}/,
keywords: KEYWORDS,
contains: [
"self"
Expand Down
2 changes: 1 addition & 1 deletion src/lib/mode_compiler.js
Expand Up @@ -24,7 +24,7 @@ export function compileLanguage(language) {
function langRe(value, global) {
return new RegExp(
regex.source(value),
'um' + (language.case_insensitive ? 'i' : '') + (global ? 'g' : '')
'm' + (language.case_insensitive ? 'i' : '') + (global ? 'g' : '')
);
}

Expand Down

0 comments on commit 3f06e89

Please sign in to comment.