Make JSON models less strict

This commit is contained in:
Lucien Greathouse
2018-05-26 16:59:09 -07:00
parent e7fe4ac3ec
commit 804bbc93b7
3 changed files with 7 additions and 6 deletions

View File

@@ -6,7 +6,11 @@ use std::collections::HashMap;
pub struct RbxInstance {
pub name: String,
pub class_name: String,
#[serde(default = "Vec::new")]
pub children: Vec<RbxInstance>,
#[serde(default = "HashMap::new")]
pub properties: HashMap<String, RbxValue>,
/// The route that this instance was generated from, if there was one.