chore: Method to return new renaming name of Mode
if any
Signed-off-by: Awiteb <a@4rs.nl>
This commit is contained in:
parent
2866872265
commit
5e040d6530
1 changed files with 10 additions and 0 deletions
|
@ -9,3 +9,13 @@ pub enum Mode {
|
|||
/// TODO
|
||||
Rename(String),
|
||||
}
|
||||
|
||||
impl Mode {
|
||||
/// TODO
|
||||
pub fn new_name(&self) -> Option<&str> {
|
||||
match &self {
|
||||
Mode::Rename(new_name) => Some(new_name),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue