Skip to content

Commit 1e831c7

Browse files
committed
fix(blueprint_models): Set current_index
1 parent 3ddcf96 commit 1e831c7

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/opengeodeweb_back/routes/models/blueprint_models.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,11 +27,12 @@ def uuid_to_flat_index():
2727
tree = ET.parse(vtm_file_path)
2828
root = tree.find("vtkMultiBlockDataSet")
2929
uuid_to_flat_index = {}
30-
current_index = 1
30+
current_index = 0
3131

3232
for elem in root.iter():
3333
if "uuid" in elem.attrib and elem.tag == "DataSet":
3434
uuid_to_flat_index[elem.attrib["uuid"]] = current_index
35+
3536
current_index += 1
3637

3738
return flask.make_response(
@@ -71,4 +72,4 @@ def extract_uuids_endpoint():
7172
return flask.make_response({"error": "File not found"}, 404)
7273

7374
uuid_dict = extract_model_uuids(flask.request.json["geode_object"], file_path)
74-
return flask.make_response({"uuid_dict": uuid_dict}, 200)
75+
return flask.make_response({"uuid_dict": uuid_dict}, 200)

0 commit comments

Comments
 (0)