mirror of
https://github.com/Llewellynvdm/exa.git
synced 2025-01-16 11:10:32 +00:00
match-to-if-let
This commit is contained in:
parent
da00e2fda2
commit
33e83accd0
@ -95,10 +95,14 @@ impl Mode {
|
|||||||
if matches.has(&flags::LONG)? {
|
if matches.has(&flags::LONG)? {
|
||||||
let details = long()?;
|
let details = long()?;
|
||||||
if matches.has(&flags::GRID)? {
|
if matches.has(&flags::GRID)? {
|
||||||
match other_options_scan()? {
|
let other_options_mode = other_options_scan()?;
|
||||||
Mode::Grid(grid) => return Ok(Mode::GridDetails(grid_details::Options { grid, details, row_threshold: Some(5) })),
|
if let Mode::Grid(grid) = other_options_mode {
|
||||||
others => return Ok(others),
|
let row_threshold = Some(5);
|
||||||
};
|
return Ok(Mode::GridDetails(grid_details::Options { grid, details, row_threshold }));
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
return Ok(other_options_mode);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return Ok(Mode::Details(details));
|
return Ok(Mode::Details(details));
|
||||||
|
Loading…
Reference in New Issue
Block a user