Make str() of Account() be its name

So we can simply hand an account instance to error messages rather than
having to call Account().getname() all the time.

This is not used yet.

Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
Sebastian Spaeth 2011-04-27 12:15:50 +02:00 committed by Nicolas Sebrecht
parent bb8546e846
commit 074ea14cf1
1 changed files with 3 additions and 0 deletions

View File

@ -125,6 +125,9 @@ class Account(CustomConfig.ConfigHelperMixin):
def getname(self):
return self.name
def __str__(self):
return self.name
def getsection(self):
return 'Account ' + self.getname()