mirror of
https://github.com/sharkdp/bat
synced 2024-11-14 16:17:20 +00:00
Add various other code refactorings
This commit is contained in:
parent
4baa346aae
commit
863d9cacd0
1 changed files with 4 additions and 5 deletions
|
@ -90,11 +90,10 @@ pub struct Config<'a> {
|
|||
|
||||
#[cfg(all(feature = "minimal-application", feature = "paging"))]
|
||||
pub fn get_pager_executable(config_pager: Option<&str>) -> Option<String> {
|
||||
if let Ok(Some(pager)) = crate::pager::get_pager(config_pager) {
|
||||
Some(pager.bin)
|
||||
} else {
|
||||
None
|
||||
}
|
||||
crate::pager::get_pager(config_pager)
|
||||
.ok()
|
||||
.flatten()
|
||||
.map(|pager| pager.bin)
|
||||
}
|
||||
|
||||
#[test]
|
||||
|
|
Loading…
Reference in a new issue