Problem
In src/runner.rs, the functions contains_sensitive_keyword and is_sensitive_arg create unnecessary indirection. The is_sensitive_arg function simply delegates to contains_sensitive_keyword without adding any value or functionality.
Proposed Solution
Combine these functions into a single is_sensitive_arg function that directly contains the logic for detecting sensitive keywords ("password", "token", "secret") in command-line arguments.
This will:
- Reduce code complexity
- Eliminate unnecessary function call overhead
- Improve code readability and maintainability
Context
This issue was identified during code review of PR #45 which adds verbose logging functionality.
References:
Requested by: @leynos
Problem
In
src/runner.rs, the functionscontains_sensitive_keywordandis_sensitive_argcreate unnecessary indirection. Theis_sensitive_argfunction simply delegates tocontains_sensitive_keywordwithout adding any value or functionality.Proposed Solution
Combine these functions into a single
is_sensitive_argfunction that directly contains the logic for detecting sensitive keywords ("password", "token", "secret") in command-line arguments.This will:
Context
This issue was identified during code review of PR #45 which adds verbose logging functionality.
References:
Requested by: @leynos