diff options
author | Akshat Agarwal <humancalico@disroot.org> | 2020-10-21 16:42:01 +0530 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-21 13:12:01 +0200 |
commit | d6c824a6c38e4d443a7f050e2f3b7703f98b2cdc (patch) | |
tree | 838d2bec35c12fba207ba5726cb784333d5d9493 /cli/lint.rs | |
parent | 0fb39f9176c5bfb6a8cd50addd85d596fe93c459 (diff) |
refactor(cli): use PathBuf instead of String for lint and fmt subcommands (#8042)
Diffstat (limited to 'cli/lint.rs')
-rw-r--r-- | cli/lint.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cli/lint.rs b/cli/lint.rs index a2a1252c0..b7ab7baa4 100644 --- a/cli/lint.rs +++ b/cli/lint.rs @@ -40,11 +40,11 @@ fn create_reporter(kind: LintReporterKind) -> Box<dyn LintReporter + Send> { } pub async fn lint_files( - args: Vec<String>, - ignore: Vec<String>, + args: Vec<PathBuf>, + ignore: Vec<PathBuf>, json: bool, ) -> Result<(), AnyError> { - if args.len() == 1 && args[0] == "-" { + if args.len() == 1 && args[0].to_string_lossy() == "-" { return lint_stdin(json); } let mut target_files = collect_files(args)?; |