Skip to content

Commit dd07a54

Browse files
authoredJul 11, 2024··
fix(linter): global variables should always check the builtin variables (#4209)
This fixes commit dbbb6fc. Closes #3374
1 parent 91dc0f7 commit dd07a54

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed
 

‎crates/oxc_linter/src/context.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ impl<'a> LintContext<'a> {
137137
}
138138

139139
pub fn env_contains_var(&self, var: &str) -> bool {
140-
if GLOBALS["builtin"].contains_key("var") {
140+
if GLOBALS["builtin"].contains_key(var) {
141141
return true;
142142
}
143143
for env in self.env().iter() {

0 commit comments

Comments
 (0)
Please sign in to comment.