Skip to content

File Filtering Logic (Possible Logic Issue) #1337

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
DeHopen opened this issue May 14, 2025 · 0 comments
Open

File Filtering Logic (Possible Logic Issue) #1337

DeHopen opened this issue May 14, 2025 · 0 comments

Comments

@DeHopen
Copy link
Contributor

DeHopen commented May 14, 2025

@yegor256

In getNonExcludedFiles:

if (!name.matches("^.*\\.java$")) { continue; }

  • Problem: If the file path uses uppercase extensions (e.g., .JAVA), it will be skipped. Also, the regex is unnecessarily complex.

  • Consequence: Some valid Java files may be ignored.

  • Fix: Use a case-insensitive check or normalize the extension before matching.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant