add exception in can_see for offsites

master
Aevann1 2022-08-20 02:10:13 +02:00
parent a8f7690dcf
commit 725179dc6c
2 changed files with 2 additions and 0 deletions

View File

@ -86,6 +86,7 @@ class Comment(Base):
@lazy @lazy
def can_see(self, v): def can_see(self, v):
if SITE != 'rdrama.net': return True
if not self.parent_submission: return True if not self.parent_submission: return True
if self.post.sub != 'chudrama': return True if self.post.sub != 'chudrama': return True
if v: if v:

View File

@ -79,6 +79,7 @@ class Submission(Base):
@lazy @lazy
def can_see(self, v): def can_see(self, v):
if SITE != 'rdrama.net': return True
if self.sub != 'chudrama': return True if self.sub != 'chudrama': return True
if v: if v:
if v.id == self.author_id: return True if v.id == self.author_id: return True