fix labelled error from shell error (#10639)

# Description

Fixes a minor error in the impl From<ShellError> for LabeledError.

# User-Facing Changes

# Tests + Formatting

# After Submitting
This commit is contained in:
Gaëtan 2023-10-08 13:09:42 +02:00 committed by GitHub
parent 4efccb2b1c
commit bcf3537395
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -75,12 +75,12 @@ impl From<ShellError> for LabeledError {
help: _help,
} => LabeledError {
label: format!("Can't convert to {expected}"),
msg: format!("can't convert {expected} to {input}"),
msg: format!("can't convert from {input} to {expected}"),
span: Some(span),
},
ShellError::DidYouMean(suggestion, span) => LabeledError {
label: "Name not found".into(),
msg: format!("did you mean '{suggestion}'"),
msg: format!("did you mean '{suggestion}'?"),
span: Some(span),
},
ShellError::PluginFailedToLoad(msg) => LabeledError {