fd
This commit is contained in:
parent
acf3ea6555
commit
302b55683b
1 changed files with 4 additions and 3 deletions
|
@ -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…
Add table
Add a link
Reference in a new issue