Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
use list instead of set
  • Loading branch information
sebastien-rosset committed Apr 15, 2020
commit 9f4d9741f895d5f6a888f3446a2c3a9a9d91dcf1
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,10 @@
path_to_item.extend(self._path_to_item)
path_to_item.append(name)
values = []
# A composed model stores child (oneof/anyOf/allOf) models under
# self._var_name_to_model_instances. A named property can exist in
# multiple child models. If the property is present in more than one
# child model, the value must be the same across all the child models.
if model_instances:
for model_instance in model_instances:
if name in model_instance._data_store:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,10 @@ def __getattr__(self, name):
path_to_item.extend(self._path_to_item)
path_to_item.append(name)
values = []
# A composed model stores child (oneof/anyOf/allOf) models under
# self._var_name_to_model_instances. A named property can exist in
# multiple child models. If the property is present in more than one
# child model, the value must be the same across all the child models.
if model_instances:
for model_instance in model_instances:
if name in model_instance._data_store:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,10 @@ def __getattr__(self, name):
path_to_item.extend(self._path_to_item)
path_to_item.append(name)
values = []
# A composed model stores child (oneof/anyOf/allOf) models under
# self._var_name_to_model_instances. A named property can exist in
# multiple child models. If the property is present in more than one
# child model, the value must be the same across all the child models.
if model_instances:
for model_instance in model_instances:
if name in model_instance._data_store:
Expand Down