diff options
Diffstat (limited to 'src/web/models')
-rw-r--r-- | src/web/models/bookmark.py | 2 | ||||
-rw-r--r-- | src/web/models/tag.py | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/web/models/bookmark.py b/src/web/models/bookmark.py index 6eee3cba..a01e6973 100644 --- a/src/web/models/bookmark.py +++ b/src/web/models/bookmark.py @@ -43,7 +43,7 @@ class Bookmark(db.Model, RightMixin): id = db.Column(db.Integer(), primary_key=True) href = db.Column(db.String(), default="") title = db.Column(db.String(), default="") - description = db.Column(db.String(), default="FR") + description = db.Column(db.String(), default="") shared = db.Column(db.Boolean(), default=False) to_read = db.Column(db.Boolean(), default=False) time = db.Column(db.DateTime(), default=datetime.utcnow) diff --git a/src/web/models/tag.py b/src/web/models/tag.py index 623808f0..76467c0b 100644 --- a/src/web/models/tag.py +++ b/src/web/models/tag.py @@ -24,7 +24,7 @@ class BookmarkTag(db.Model): text = db.Column(db.String, unique=False) # foreign keys - user_id = db.Column(db.Integer, db.ForeignKey('user.id')) + user_id = db.Column(db.Integer, db.ForeignKey('user.id', ondelete='CASCADE')) bookmark_id = db.Column(db.Integer, db.ForeignKey('bookmark.id', ondelete='CASCADE')) # relationships |