@@ -22,8 +22,7 @@ pub struct JsonTree<Size: size::Size> {
2222 /// The main data of the tree.
2323 #[ deref]
2424 #[ deref_mut]
25- #[ cfg_attr( feature = "json" , serde( flatten) ) ]
26- pub data : DataTreeReflection < String , Size > ,
25+ pub tree : DataTreeReflection < String , Size > ,
2726 /// Optional list of shared inodes, their sizes, and their many links.
2827 #[ cfg_attr( feature = "json" , serde( skip_serializing_if = "Option::is_none" ) ) ]
2928 pub shared_inodes : Option < HardlinkListReflection < Size > > ,
@@ -32,7 +31,7 @@ pub struct JsonTree<Size: size::Size> {
3231/// The `"unit"` field and the `"tree"` field of [`JsonData`].
3332#[ derive( Debug , Clone , From , TryInto ) ]
3433#[ cfg_attr( feature = "json" , derive( Deserialize , Serialize ) ) ]
35- #[ cfg_attr( feature = "json" , serde( tag = "unit" , content = "tree" ) ) ]
34+ #[ cfg_attr( feature = "json" , serde( tag = "unit" ) ) ]
3635#[ cfg_attr( feature = "json" , serde( rename_all = "kebab-case" ) ) ]
3736pub enum UnitAndTree {
3837 /// Tree where size is [bytes](Bytes).
0 commit comments