mirror of
https://github.com/nushell/nushell.git
synced 2025-01-08 23:40:17 +01:00
clippy errors
This commit is contained in:
parent
5a6aebfcb2
commit
6731e3542d
@ -401,7 +401,7 @@ pub fn report_shell_error(
|
|||||||
Diagnostic::error()
|
Diagnostic::error()
|
||||||
.with_message("External command")
|
.with_message("External command")
|
||||||
.with_labels(vec![
|
.with_labels(vec![
|
||||||
Label::primary(diag_file_id, diag_range).with_message(format!("{}", error))
|
Label::primary(diag_file_id, diag_range).with_message(error.to_string())
|
||||||
])
|
])
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -46,7 +46,7 @@ impl<'call, 'contex> ExternalCommand<'call, 'contex> {
|
|||||||
call: &'call Call,
|
call: &'call Call,
|
||||||
context: &'contex EvaluationContext,
|
context: &'contex EvaluationContext,
|
||||||
) -> Result<Self, ShellError> {
|
) -> Result<Self, ShellError> {
|
||||||
if call.positional.len() == 0 {
|
if call.positional.is_empty() {
|
||||||
return Err(ShellError::ExternalNotSupported(call.head));
|
return Err(ShellError::ExternalNotSupported(call.head));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user