mirror of
https://github.com/nushell/nushell.git
synced 2025-07-01 07:00:37 +02:00
Remove Span::unknown (#525)
This commit is contained in:
@ -55,7 +55,7 @@ impl GStat {
|
||||
}
|
||||
None => Spanned {
|
||||
item: ".".to_string(),
|
||||
span: Span::unknown(),
|
||||
span: *span,
|
||||
},
|
||||
};
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
use crate::GStat;
|
||||
use nu_plugin::{EvaluatedCall, LabeledError, Plugin};
|
||||
use nu_protocol::{Category, Signature, Span, Spanned, SyntaxShape, Value};
|
||||
use nu_protocol::{Category, Signature, Spanned, SyntaxShape, Value};
|
||||
|
||||
impl Plugin for GStat {
|
||||
fn signature(&self) -> Vec<Signature> {
|
||||
@ -17,9 +17,7 @@ impl Plugin for GStat {
|
||||
input: &Value,
|
||||
) -> Result<Value, LabeledError> {
|
||||
if name != "gstat" {
|
||||
return Ok(Value::Nothing {
|
||||
span: Span::unknown(),
|
||||
});
|
||||
return Ok(Value::Nothing { span: call.head });
|
||||
}
|
||||
|
||||
let repo_path: Option<Spanned<String>> = call.opt(0)?;
|
||||
|
Reference in New Issue
Block a user