From 4812c18a1dde723e80e6fb5eace7ca6368623a03 Mon Sep 17 00:00:00 2001 From: LukeItUp Date: Thu, 3 Sep 2020 11:28:57 +0200 Subject: [PATCH] structure id fix --- src/lib/structure_conversions.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/lib/structure_conversions.py b/src/lib/structure_conversions.py index 4ba8a8e..03040ef 100644 --- a/src/lib/structure_conversions.py +++ b/src/lib/structure_conversions.py @@ -26,7 +26,7 @@ def build_structure_conversions(): vto_structure = line[1].strip().split(">")[1].split("<")[0] vto_name = line[2].strip() - vto_id = line[4].strip() + vto_id = line[6].strip() if 0 in (len(vto_name), len(vto_id)): continue @@ -41,16 +41,16 @@ def convert_structure(structure, type): for vfrom, vto_name, vto_structure, vto_id in structure_conversions: match = structure.match(vfrom) - # fix for ids 65, 66, 67 which instead matched with 64 - if match and vto_id == '64' and '-s' in type: + # fix for ids 106, 107, 44 which instead matched with 30 + if match and vto_id == '30' and '-s' in type: vto_name = 's0-vp-s0' - vto_id = '65' - elif match and vto_id == '64' and '-g' in type: + vto_id = '106' + elif match and vto_id == '30' and '-g' in type: vto_name = 'gg-vp-gg' - vto_id = '66' - elif match and vto_id == '64' and '-r' in type: + vto_id = '107' + elif match and vto_id == '30' and '-r' in type: vto_name = 'r-vp-r' - vto_id = '67' + vto_id = '44' if match: # we need to remove replace alias here as we want to use javascript's one