mirror of
https://github.com/sharkdp/bat.git
synced 2025-01-31 10:11:07 +00:00
Add various other code refactorings
This commit is contained in:
parent
4baa346aae
commit
863d9cacd0
@ -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…
x
Reference in New Issue
Block a user