Przeglądaj źródła

Merge pull request #6719 from ulyssessouza/fix-release-script

Fix release script for null user
Ulysses Souza 6 lat temu
rodzic
commit
e1baa90f6b
1 zmienionych plików z 2 dodań i 0 usunięć
  1. 2 0
      script/release/release/repository.py

+ 2 - 0
script/release/release/repository.py

@@ -220,6 +220,8 @@ def get_contributors(pr_data):
     commits = pr_data.get_commits()
     authors = {}
     for commit in commits:
+        if not commit or not commit.author or not commit.author.login:
+            continue
         author = commit.author.login
         authors[author] = authors.get(author, 0) + 1
     return [x[0] for x in sorted(list(authors.items()), key=lambda x: x[1])]