forked from MarseyWorld/MarseyWorld
fdsfsd
parent
85221192c6
commit
ae6c8d9ee7
|
@ -220,6 +220,12 @@ class Submission(Base):
|
||||||
elif "youtu.be" in self.domain or "youtube.com" == self.domain: return f"https://{site}/assets/images/default_thumb_yt.webp"
|
elif "youtu.be" in self.domain or "youtube.com" == self.domain: return f"https://{site}/assets/images/default_thumb_yt.webp"
|
||||||
else: return f"https://{site}/assets/images/default_thumb_link.webp"
|
else: return f"https://{site}/assets/images/default_thumb_link.webp"
|
||||||
|
|
||||||
|
@property
|
||||||
|
@lazy
|
||||||
|
def full_thumb(self):
|
||||||
|
if self.thumb_url.startswith('/'): return 'https://rdrama.net' + self.thumb_url
|
||||||
|
return self.thumb_url
|
||||||
|
|
||||||
@property
|
@property
|
||||||
@lazy
|
@lazy
|
||||||
def json_raw(self):
|
def json_raw(self):
|
||||||
|
@ -235,7 +241,7 @@ class Submission(Base):
|
||||||
'title': self.title,
|
'title': self.title,
|
||||||
'is_nsfw': self.over_18,
|
'is_nsfw': self.over_18,
|
||||||
'is_bot': self.is_bot,
|
'is_bot': self.is_bot,
|
||||||
'thumb_url': self.thumb_url,
|
'thumb_url': self.full_thumb,
|
||||||
'domain': self.domain,
|
'domain': self.domain,
|
||||||
'url': self.url,
|
'url': self.url,
|
||||||
'body': self.body,
|
'body': self.body,
|
||||||
|
|
Loading…
Reference in New Issue