summaryrefslogtreecommitdiff
path: root/cli/lint.rs
diff options
context:
space:
mode:
authorAkshat Agarwal <humancalico@disroot.org>2020-10-21 16:42:01 +0530
committerGitHub <noreply@github.com>2020-10-21 13:12:01 +0200
commitd6c824a6c38e4d443a7f050e2f3b7703f98b2cdc (patch)
tree838d2bec35c12fba207ba5726cb784333d5d9493 /cli/lint.rs
parent0fb39f9176c5bfb6a8cd50addd85d596fe93c459 (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.rs6
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)?;