Skip to content

Commit

Permalink
Fix(flixTor): fix presence not showing (PreMiD#6505)
Browse files Browse the repository at this point in the history
  • Loading branch information
RisingSunLight42 authored Jul 27, 2022
1 parent 60896d5 commit cce99e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion websites/F/FlixTor/dist/metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"flixtor.cz"
],
"regExp": "flixtor[.](to|ch|se|vc|nu|sx|tk|cz)",
"version": "2.3.2",
"version": "2.3.3",
"logo": "https://i.imgur.com/FIXyNZo.png",
"thumbnail": "https://i.imgur.com/iaHbvZ7.png",
"color": "#1d3343",
Expand Down
6 changes: 3 additions & 3 deletions websites/F/FlixTor/presence.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
const presence = new Presence({
clientId: "616754182858342426",
clientId: "1001112348192423946",
}),
strings = presence.getStrings({
play: "presence.playback.playing",
Expand Down Expand Up @@ -45,7 +45,8 @@ presence.on("UpdateData", async () => {
);
presenceData.largeImageKey = document
.querySelector<HTMLMetaElement>('meta[property="og:image"]')
.getAttribute("content");
.getAttribute("content")
.replace("https:https:", "https:");

presenceData.smallImageKey = video.paused ? "pause" : "play";
presenceData.smallImageText = video.paused
Expand Down Expand Up @@ -111,7 +112,6 @@ presence.on("UpdateData", async () => {
delete presenceData.startTimestamp;
delete presenceData.endTimestamp;
}

if (videoTitle) presence.setActivity(presenceData, !video.paused);
}
});

0 comments on commit cce99e2

Please sign in to comment.