SQLA migration: fix RemovedIn20Warning
s
This commit is contained in:
parent
449e2557d0
commit
ff09ba4209
4 changed files with 11 additions and 15 deletions
|
@ -194,12 +194,9 @@ class Comment(Base):
|
|||
@property
|
||||
@lazy
|
||||
def parent(self):
|
||||
|
||||
if not self.parent_submission: return None
|
||||
|
||||
if self.level == 1: return self.post
|
||||
|
||||
else: return g.db.query(Comment).get(self.parent_comment_id)
|
||||
else: return g.db.get(Comment, self.parent_comment_id)
|
||||
|
||||
@property
|
||||
@lazy
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue