mirror of
https://github.com/evennia/evennia.git
synced 2026-04-04 23:17:17 +02:00
Fixed a ZeroDivionError by adjusting what is returned by aliashandler.all() when no aliases are given ([] instead of ['']). Also made sure src.utils.stringsuggestions() don't crash in such a situation.
This commit is contained in:
parent
a1646ec596
commit
55423f6a2f
4 changed files with 9 additions and 7 deletions
|
|
@ -592,7 +592,7 @@ class TagHandler(object):
|
|||
|
||||
def all(self):
|
||||
"Get all tags in this handler"
|
||||
return [to_str(p[0]) for p in _GA(self.obj, self._m2m_fieldname).all().values_list("db_key")]
|
||||
return [to_str(p[0]) for p in _GA(self.obj, self._m2m_fieldname).all().values_list("db_key") if p[0]]
|
||||
|
||||
def __str__(self):
|
||||
return ",".join(self.all())
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue