mirror of
https://github.com/nushell/nushell.git
synced 2025-08-09 09:05:47 +02:00
Invert &Option
s to Option<&T>
(#10315)
Elide the reference for `Copy` type (`usize`) Use the canonical deref where possible. * `&Box` -> `&` * `&String` -> `&str` * `&PathBuf` -> `&Path` Skips the ctrl-C handler for now.
This commit is contained in:
committed by
GitHub
parent
3e14dc3eb8
commit
a14e9e0a2e
@ -1,4 +1,4 @@
|
||||
use std::path::PathBuf;
|
||||
use std::path::Path;
|
||||
|
||||
use crate::{ast::Call, Alias, BlockId, Example, PipelineData, ShellError, Signature};
|
||||
|
||||
@ -92,7 +92,7 @@ pub trait Command: Send + Sync + CommandClone {
|
||||
}
|
||||
|
||||
// Is a plugin command (returns plugin's path, type of shell if the declaration is a plugin)
|
||||
fn is_plugin(&self) -> Option<(&PathBuf, &Option<PathBuf>)> {
|
||||
fn is_plugin(&self) -> Option<(&Path, Option<&Path>)> {
|
||||
None
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user