Fix empty zipping bug

This commit is contained in:
YishiMichael 2022-03-30 22:09:26 +08:00
parent 9bbbed3a83
commit 637d779190
No known key found for this signature in database
GPG key ID: EC615C0C5A86BC80

View file

@ -399,6 +399,9 @@ class LabelledString(_StringSVG):
])
def get_group_substr_items(self) -> tuple[list[Span], list[str]]:
if not self.submob_labels:
return [], []
group_labels, submob_spans = zip(
*self.compress_neighbours(self.submob_labels)
)