diff --git a/update.py b/update.py index f0df237..e88b620 100755 --- a/update.py +++ b/update.py @@ -18,7 +18,10 @@ for ext in exts: if ext["updateMethod"] == "github": with urlopen(ext["updateUrl"]) as r: latest = json.load(r)[0] - ext["url"] = latest["assets"][0]["browser_download_url"] + for asset in latest["assets"]: + if asset["browser_download_url"].endswith(".crx"): + ext["url"] = asset["browser_download_url"] + break with urlopen(ext["url"]) as blob: sha256 = hashlib.new("SHA256") if blob.status == 200: