add timestamps for rich metadata info on discord
This commit is contained in:
@@ -209,6 +209,9 @@ def now():
|
|||||||
now = datetime.datetime.now()
|
now = datetime.datetime.now()
|
||||||
return now.strftime("%Y-%m-%d %H:%M:%S")
|
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'):
|
def human_duration(s, sig='dhms'):
|
||||||
|
|
||||||
|
@@ -1145,7 +1145,8 @@ class DISCORD(Notifier):
|
|||||||
plex_url = pretty_metadata.get_plex_url()
|
plex_url = pretty_metadata.get_plex_url()
|
||||||
|
|
||||||
# Build Discord post attachment
|
# Build Discord post attachment
|
||||||
attachment = {'title': title
|
attachment = {'title': title,
|
||||||
|
'timestamp': helpers.utc_now_iso()
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.config['color']:
|
if self.config['color']:
|
||||||
|
Reference in New Issue
Block a user