Skip to content

Commit

Permalink
use lazy_static!
Browse files Browse the repository at this point in the history
  • Loading branch information
baseballyama committed Dec 28, 2024
1 parent 9397578 commit 58bf5ac
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/oxc_linter/src/rules/eslint/no_octal_escape.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ impl Rule for NoOctalEscape {
fn run<'a>(&self, node: &AstNode<'a>, ctx: &LintContext<'a>) {
if let AstKind::StringLiteral(literal) = node.kind() {
if let Some(raw) = &literal.raw {
if let Some(captures) = CUSTOM_ERROR_REGEX_PATTERN.captures(raw) {
if let Some(captures) = OCTAL_ESCAPE_PATTERN.captures(raw) {
if let Some(sequence) = captures.get(1) {
ctx.diagnostic(no_octal_escape_diagnostic(literal.span, sequence.as_str()));
}
Expand Down

0 comments on commit 58bf5ac

Please sign in to comment.