mirror of
https://github.com/nushell/nushell.git
synced 2024-12-01 12:54:16 +01:00
Eliminate warning on not used param path
This commit is contained in:
parent
b0614deb14
commit
5dafde462a
@ -268,11 +268,11 @@ pub mod pwd_per_drive_singleton {
|
|||||||
/// set_pwd_per_drive
|
/// set_pwd_per_drive
|
||||||
/// record PWD for drive, path must be absolute path
|
/// record PWD for drive, path must be absolute path
|
||||||
/// return Ok(()) if succeeded, otherwise error message
|
/// return Ok(()) if succeeded, otherwise error message
|
||||||
pub fn set_pwd_per_drive(path: &Path) -> Result<(), String> {
|
pub fn set_pwd_per_drive(_path: &Path) -> Result<(), String> {
|
||||||
cfg_if::cfg_if! { if #[cfg(target_os="windows")] {
|
cfg_if::cfg_if! { if #[cfg(target_os="windows")] {
|
||||||
|
|
||||||
if let Ok(mut pwd_per_drive) = get_drive_pwd_map().lock() {
|
if let Ok(mut pwd_per_drive) = get_drive_pwd_map().lock() {
|
||||||
pwd_per_drive.set_pwd(path)
|
pwd_per_drive.set_pwd(_path)
|
||||||
} else {
|
} else {
|
||||||
Err("Failed to lock map".to_string())
|
Err("Failed to lock map".to_string())
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user