mirror of
https://github.com/nushell/nushell.git
synced 2025-05-30 06:39:33 +02:00
fix(cell-path): incorrect serialization of empty cell-paths
can round trip `$. | to nuon | from nuon`
This commit is contained in:
parent
e48ad0d531
commit
d411a1e9e6
@ -250,6 +250,10 @@ impl Display for CellPath {
|
||||
}
|
||||
}
|
||||
}
|
||||
// Empty cell-paths are `$.` not `$`
|
||||
if self.members.is_empty() {
|
||||
write!(f, ".")?;
|
||||
}
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user