Skip to content

Commit

Permalink
WIP3
Browse files Browse the repository at this point in the history
  • Loading branch information
Mahaki-Leach committed Jan 7, 2025
1 parent c5ca81c commit f2f2ef1
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions property_packages/modular/template_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"""

def build_config(property_package_name, compound_names: List[str], valid_states: List[States]) -> dict[str,any]:

# Build list of compound objects

compounds = []
Expand Down Expand Up @@ -42,7 +42,9 @@ def build_config(property_package_name, compound_names: List[str], valid_states:

for key, obj in template.items():
# Call the parse method on each object and update the template
new_template[key] = obj.serialise(compounds, valid_states)
config = obj.serialise(compounds, valid_states)
if config is not None:
new_template[key] = config

# Building property package and returning
return GenericExtendedParameterBlock(**new_template)
return GenericExtendedParameterBlock(**new_template)

0 comments on commit f2f2ef1

Please sign in to comment.