[TASK] Beautify representation for base Message class.

This commit is contained in:
Jan Philipp Timme 2015-10-25 13:00:40 +01:00
parent 82dcbed476
commit b5ff903d64
1 changed files with 3 additions and 0 deletions

3
irc.py
View File

@ -65,6 +65,9 @@ class Message(object):
def __repr__(self): def __repr__(self):
items = self.__dict__.copy() items = self.__dict__.copy()
if len(items) == 1:
items = items["data"]
for e in ["prefix", "nick", "host", "ident"]: del items[e]
e = [] e = []
for key in items: for key in items:
if key == "data": if key == "data":