Don't crash on invalid categories.

This commit is contained in:
Michael Herzberg 2019-05-21 22:31:04 +01:00
parent 441c8b3779
commit 40dfa3f593
1 changed files with 1 additions and 1 deletions

View File

@ -54,7 +54,7 @@ def get_metadata(overview_contents):
# Extracts extension categories
match = re.search(
"""Attribute name="category">(.+?)</Attribute>""", overview_contents)
categories = match.group(1).split(",") if match else None
categories = match.group(1).split(",") if match else []
# Extracts the number of downloads
match = re.search(