From: Aaron Bentley Date: Mon, 9 May 2005 21:56:10 +0000 (+0000) Subject: Slight refactoring X-Git-Tag: 1.0.0~296 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=bb04137c9c04edee3c48a98682d5714a08d9de47;p=be.git Slight refactoring --- diff --git a/libbe/diff.py b/libbe/diff.py index 70bda69..a0e43a2 100644 --- a/libbe/diff.py +++ b/libbe/diff.py @@ -60,7 +60,7 @@ def change_lines(old, new, attributes): old_attr = getattr(old, attr) new_attr = getattr(new, attr) if old_attr != new_attr: - change_list.append("%s: %s -> %s" % (attr, old_attr, new_attr)) + change_list.append((attr, old_attr, new_attr)) if len(change_list) >= 0: return change_list else: @@ -72,6 +72,6 @@ def bug_changes(old, new, bugs): if len(change_list) == 0: return None return "%s%s\n" % (cmdutil.bug_summary(new, bugs, shortlist=True), - "\n".join(change_list)) + "\n".join(["%s: %s -> %s" % f for f in change_list]))