forked from rDrama/rDrama
master
parent
3737b93b0d
commit
0a399bf41c
|
@ -310,12 +310,13 @@ class Submission(Base, Stndrd, Age_times, Scores, Fuzzing):
|
||||||
def realurl(self, v):
|
def realurl(self, v):
|
||||||
if v and v.agendaposter and random.randint(1, 10) < 4:
|
if v and v.agendaposter and random.randint(1, 10) < 4:
|
||||||
return 'https://secure.actblue.com/donate/ms_blm_homepage_2019'
|
return 'https://secure.actblue.com/donate/ms_blm_homepage_2019'
|
||||||
elif self.url.startswith("https://old.reddit.com/"):
|
elif v and self.url.startswith("https://old.reddit.com/"):
|
||||||
url = self.url
|
url = self.url
|
||||||
if v and not v.oldreddit: url = self.url.replace("old.reddit.com", "reddit.com")
|
if not v.oldreddit: url = self.url.replace("old.reddit.com", "reddit.com")
|
||||||
if v and v.controversial and '/comments/' in url:
|
if v.controversial and '/comments/' in url:
|
||||||
if "?" in url: url += "&sort=controversial"
|
if "?" in url: url += "&sort=controversial"
|
||||||
else: url += "/?sort=controversial"
|
else: url += "/?sort=controversial"
|
||||||
|
return url
|
||||||
return ""
|
return ""
|
||||||
|
|
||||||
@property
|
@property
|
||||||
|
|
Loading…
Reference in New Issue