Fix the default value for comma separated lists

master
Pierre Jaury 8 years ago
parent 163494cb78
commit c07211677c

@ -135,7 +135,7 @@ class User(Email):
# Filters
forward_enabled = db.Column(db.Boolean(), nullable=False, default=False)
forward_destination = db.Column(CommaSeparatedList, nullable=True, default=None)
forward_destination = db.Column(CommaSeparatedList, nullable=True, default=[])
reply_enabled = db.Column(db.Boolean(), nullable=False, default=False)
reply_subject = db.Column(db.String(255), nullable=True, default=None)
reply_body = db.Column(db.Text(), nullable=True, default=None)
@ -189,7 +189,7 @@ class Alias(Email):
"""
domain = db.relationship(Domain,
backref=db.backref('aliases', cascade='all, delete-orphan'))
destination = db.Column(CommaSeparatedList, nullable=False)
destination = db.Column(CommaSeparatedList, nullable=False, default=[])
class Fetch(Base):

Loading…
Cancel
Save