commit: ddb7cf01f01d7175cdab348b9d94b0994695e337
Author: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
AuthorDate: Mon Nov 9 02:37:15 2015 +0000
Commit: Brian Dolbec <dolsen <AT> gentoo <DOT> org>
CommitDate: Mon Nov 9 02:37:15 2015 +0000
URL: https://gitweb.gentoo.org/proj/gentoolkit.git/commit/?id=ddb7cf01
equery/meta.py: Revert the changes to the verbose section or format_maintainers
The last change would always print the first string even if the maint attribute
was None.
This was due to the string always being non-empty.
The original code there was correct.
It was only the maint.email assignment that was in error.
pym/gentoolkit/equery/meta.py | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/pym/gentoolkit/equery/meta.py b/pym/gentoolkit/equery/meta.py
index 1a07999..8af5744 100644
--- a/pym/gentoolkit/equery/meta.py
+++ b/pym/gentoolkit/equery/meta.py
@@ -181,9 +181,9 @@ def format_maintainers(maints):
for maint in maints:
maintstr = maint.email or ''
if CONFIG['verbose']:
- maintstr += " (%s)" % (maint.name or'')
- maintstr += " - %s" % (maint.restrict or '')
- maintstr += "\n%s" % (maint.description or '')
+ maintstr += " (%s)" % (maint.name) if maint.name else ''
+ maintstr += " - %s" % (maint.restrict) if
maint.restrict else ''
+ maintstr += "\n%s" % (maint.description) if
maint.description else ''
result.append(maintstr)
return result