fix lints
This commit is contained in:
parent
d943a51e3e
commit
814dcfa8d2
2 changed files with 4 additions and 3 deletions
|
@ -54,7 +54,7 @@ impl Client {
|
||||||
port_arg: Option<String>,
|
port_arg: Option<String>,
|
||||||
id: usize,
|
id: usize,
|
||||||
) -> Result<(Self, UnboundedReceiver<Payload>)> {
|
) -> Result<(Self, UnboundedReceiver<Payload>)> {
|
||||||
if command == "" {
|
if command.is_empty() {
|
||||||
return Result::Err(Error::Other(anyhow!("Command not provided")));
|
return Result::Err(Error::Other(anyhow!("Command not provided")));
|
||||||
}
|
}
|
||||||
if transport == "tcp" && port_arg.is_some() {
|
if transport == "tcp" && port_arg.is_some() {
|
||||||
|
|
|
@ -232,9 +232,10 @@ pub fn dap_start_impl(
|
||||||
if cfg.completion == Some("filename".to_owned())
|
if cfg.completion == Some("filename".to_owned())
|
||||||
|| cfg.completion == Some("directory".to_owned())
|
|| cfg.completion == Some("directory".to_owned())
|
||||||
{
|
{
|
||||||
param = std::fs::canonicalize(x).ok()
|
param = std::fs::canonicalize(x)
|
||||||
|
.ok()
|
||||||
.and_then(|pb| pb.into_os_string().into_string().ok())
|
.and_then(|pb| pb.into_os_string().into_string().ok())
|
||||||
.unwrap_or(x.to_string());
|
.unwrap_or_else(|| x.to_string());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// For param #0 replace {0} in args
|
// For param #0 replace {0} in args
|
||||||
|
|
Loading…
Reference in a new issue