add timestamps for rich metadata info on discord

This commit is contained in:
samwiseg00 2018-05-27 17:44:35 -04:00
parent 4884cee309
commit ddb7fa04ca
2 changed files with 11 additions and 7 deletions

View file

@ -209,6 +209,9 @@ def now():
now = datetime.datetime.now()
return now.strftime("%Y-%m-%d %H:%M:%S")
def utc_now_iso():
utcnow = datetime.datetime.utcnow()
return utcnow.isoformat()
def human_duration(s, sig='dhms'):

View file

@ -1145,7 +1145,8 @@ class DISCORD(Notifier):
plex_url = pretty_metadata.get_plex_url()
# Build Discord post attachment
attachment = {'title': title
attachment = {'title': title,
'timestamp': helpers.utc_now_iso()
}
if self.config['color']: