From dff485cb7e2d7b7770d53cd85238c25fac804476 Mon Sep 17 00:00:00 2001
From: Thomas Woerner <twoerner@redhat.com>
Date: Mon, 30 Nov 2020 15:48:35 +0100
Subject: [PATCH] utils/changelog: Fix get_commit to use proper variable

The function get_commit was using the global merge variable instead of
the local commit variable. Therefore it returned the wrong commit
subject for merges without subject.
---
 utils/changelog | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/utils/changelog b/utils/changelog
index 2e5e5164..9607063d 100755
--- a/utils/changelog
+++ b/utils/changelog
@@ -87,7 +87,7 @@ def store(commits, prs, authors, commit, author, merge, msg):
 
 def get_commit(commits, commit):
     _commits = [value for key, value in commits.items()
-                if key.startswith(merge)]
+                if key.startswith(commit)]
     if len(_commits) == 1:
         return _commits[0]
     return commit
-- 
GitLab