Fixed all unit.add_si_unit uses after fd87747

Now they were causing `TypeError: Usecase.__init__() got an unexpected keyword argument 'name'`
This commit is contained in:
Andrej730
2023-04-03 17:42:33 +05:00
parent 3095521e36
commit 75d3da9908
7 changed files with 22 additions and 20 deletions
@@ -42,7 +42,7 @@ class LibraryGenerator:
ifcopenshell.api.run(
"project.assign_declaration", self.file, definition=self.library, relating_context=self.project
)
unit = ifcopenshell.api.run("unit.add_si_unit", self.file, unit_type="LENGTHUNIT", name="METRE", prefix="MILLI")
unit = ifcopenshell.api.run("unit.add_si_unit", self.file, unit_type="LENGTHUNIT", prefix="MILLI")
ifcopenshell.api.run("unit.assign_unit", self.file, units=[unit])
model = ifcopenshell.api.run("context.add_context", self.file, context_type="Model")