Yet another small fix

This commit is contained in:
Patrick Jentsch 2023-02-24 10:02:28 +01:00
parent 122cce98a1
commit ff3ac3658f

View File

@ -542,7 +542,8 @@ class User(HashidMixin, UserMixin, db.Model):
) )
followed_corpora = association_proxy( followed_corpora = association_proxy(
'corpus_follower_associations', 'corpus_follower_associations',
'corpus' 'corpus',
creator=lambda c: CorpusFollowerAssociation(corpus=c)
) )
jobs = db.relationship( jobs = db.relationship(
'Job', 'Job',
@ -1499,7 +1500,8 @@ class Corpus(HashidMixin, db.Model):
) )
followers = association_proxy( followers = association_proxy(
'corpus_follower_associations', 'corpus_follower_associations',
'follower' 'follower',
creator=lambda u: CorpusFollowerAssociation(follower=u)
) )
user = db.relationship('User', back_populates='corpora') user = db.relationship('User', back_populates='corpora')
# "static" attributes # "static" attributes