From ed79568deb6f7e0e1450dd548a6a53abe4f8a887 Mon Sep 17 00:00:00 2001 From: "John T. Wodder II" Date: Mon, 26 Feb 2024 11:07:49 -0500 Subject: [PATCH] Handle null `closed_by` fields --- src/solidation/__main__.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/solidation/__main__.py b/src/solidation/__main__.py index 3c9122d..37e550e 100644 --- a/src/solidation/__main__.py +++ b/src/solidation/__main__.py @@ -425,8 +425,8 @@ def to_markdown(self) -> str: def get_by_counts(iterable: Iterable[Any], attr: str) -> Counter[str]: counts: Counter[str] = Counter() for i in iterable: - name = getattr(i, attr).login - counts[name] += 1 + if (actor := getattr(i, attr, None)) is not None: + counts[actor.login] += 1 return counts