mirror of
https://github.com/sharkdp/bat.git
synced 2026-10-28 08:05:55 +00:00
Small refactoring, handle invalid UTF-8 filenames
This commit is contained in:
1 parent
83d408bab3
commit
34619a2e89
5 files changed
+47
-25
No files matched your search
+1
-1
@@ -36,7 +36,7 @@ impl<'b> Controller<'b> {
|
||||
if self.config.paging_mode != PagingMode::Never {
|
||||
let call_pager = self.config.files.iter().any(|file| {
|
||||
if let InputFile::Ordinary(ofile) = file {
|
||||
return Path::new(ofile.filename()).exists();
|
||||
return Path::new(ofile.provided_path()).exists();
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user