Correct scoping for variable (linting)