Automatically append HTTP root to newsletter URL
This commit is contained in:
@@ -78,8 +78,8 @@ def notify(newsletter_id=None, notify_action=None, **kwargs):
|
||||
return
|
||||
|
||||
if notify_action in ('test', 'api'):
|
||||
subject = kwargs.pop('subject', newsletter_config['subject'])
|
||||
body = kwargs.pop('body', newsletter_config['body'])
|
||||
subject = kwargs.pop('subject', None) or newsletter_config['subject']
|
||||
body = kwargs.pop('body', None) or newsletter_config['body']
|
||||
else:
|
||||
subject = newsletter_config['subject']
|
||||
body = newsletter_config['body']
|
||||
|
@@ -455,7 +455,7 @@ class Newsletter(object):
|
||||
'start_date': self.start_date.format(date_format),
|
||||
'end_date': self.end_date.format(date_format),
|
||||
'newsletter_days': self.config['last_days'],
|
||||
'newsletter_url': base_url.rstrip('/') + '/newsletter/' + self.uuid,
|
||||
'newsletter_url': base_url.rstrip('/') + plexpy.HTTP_ROOT + 'newsletter/' + self.uuid,
|
||||
'newsletter_uuid': self.uuid
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user