mirror of
https://github.com/Mastermindzh/tidal-hifi.git
synced 2025-08-03 11:31:20 +02:00
Merge branch 'master' of github.com:Mastermindzh/tidal-hifi into feature/tidalControllers
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
"openapi": "3.1.0",
|
||||
"info": {
|
||||
"title": "TIDAL Hi-Fi API",
|
||||
"version": "5.17.0",
|
||||
"version": "5.18.0",
|
||||
"description": "",
|
||||
"license": {
|
||||
"name": "MIT",
|
||||
|
File diff suppressed because it is too large
Load Diff
@@ -313,6 +313,7 @@ function updateMpris(mediaInfo: MediaInfo) {
|
||||
"xesam:title": mediaInfo.title,
|
||||
"xesam:artist": [mediaInfo.artists],
|
||||
"xesam:album": mediaInfo.album,
|
||||
"xesam:url": mediaInfo.url,
|
||||
"mpris:artUrl": mediaInfo.image,
|
||||
"mpris:length": convertDurationToSeconds(mediaInfo.duration) * 1000 * 1000,
|
||||
"mpris:trackid": "/org/mpris/MediaPlayer2/track/" + tidalController.getTrackId(),
|
||||
|
@@ -103,8 +103,7 @@ const getActivity = (): SetActivity => {
|
||||
if (includeTimestamps) {
|
||||
const currentSeconds = convertDurationToSeconds(mediaInfo.current);
|
||||
const durationSeconds = convertDurationToSeconds(mediaInfo.duration);
|
||||
const date = new Date();
|
||||
const now = Math.floor(date.getTime() / 1000);
|
||||
const now = Math.trunc((Date.now() + 500) / 1000);
|
||||
presence.startTimestamp = now - currentSeconds;
|
||||
presence.endTimestamp = presence.startTimestamp + durationSeconds;
|
||||
}
|
||||
|
Reference in New Issue
Block a user