rather than just always allowing additional properties, only return
true if any of the available schemas allows it
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
}
fn additional_properties(&self) -> bool {
- true
+ self.list.iter().any(|schema| {
+ schema
+ .any_object()
+ .expect("non-object-schema in `AllOfSchema`")
+ .additional_properties()
+ })
}
fn default_key(&self) -> Option<&'static str> {
}
fn additional_properties(&self) -> bool {
- true
+ self.list.iter().any(|(_, schema)| {
+ schema
+ .any_object()
+ .expect("non-object-schema in `OneOfSchema`")
+ .additional_properties()
+ })
}
fn default_key(&self) -> Option<&'static str> {