commit a1b6edad1f86f046665762a2195c0f9a2c8e0016
Author: Pierre-Yves Chibon <pingou(a)pingoured.fr>
Date: Tue Dec 1 12:14:06 2015 +0100
Check if the person who approved the review is the assignee or not
Fixes
https://github.com/fedora-infra/packagedb-cli/issues/58
pkgdb2client/utils.py | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/pkgdb2client/utils.py b/pkgdb2client/utils.py
index c19dcf9..adb1b18 100644
--- a/pkgdb2client/utils.py
+++ b/pkgdb2client/utils.py
@@ -261,6 +261,10 @@ def check_package_creation(info, bugid, pkgdbclient):
messages["bad"].append(
'Review approved by the person creating '
'the ticket {0}'.format(flag_setter))
+ if flag_setter != bug.comments[0].author:
+ messages["bad"].append(
+ 'Review not approved by the assignee of '
+ 'the ticket {0}'.format(flag_setter))
else:
messages["bad"].append(
'Review not approved, flag set to: {0}'.format(