feat: Allow underscores and hyphens in account name

This commit is contained in:
Jérôme BECOT
2021-11-19 00:34:16 +01:00
parent beed738d02
commit a3c50828a6
3 changed files with 9 additions and 9 deletions

View File

@ -35,7 +35,7 @@ class Account(db.Model):
if self.name is not None:
self.name = ''.join(c for c in self.name.lower()
if c in "abcdefghijklmnopqrstuvwxyz0123456789")
if c in "abcdefghijklmnopqrstuvwxyz0123456789_-")
def __repr__(self):
return '<Account {0}r>'.format(self.name)