Skip to content

Commit

Permalink
fix: deleted unnecessary commentand change document.URL to location.href
Browse files Browse the repository at this point in the history
  • Loading branch information
pupiesa committed Dec 29, 2024
1 parent f084a96 commit 64c3430
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions websites/D/Dek-d/presence.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,9 +81,7 @@ presence.on("UpdateData", async () => {
type: ActivityType.Watching,
// initial details in case of no match displaying the 1st path segment
details: `Browsing ${pathSegments[1]}`,
// buttons: [{ label: "Visit", url: document.URL }],
},
// board thread play function
}, // board thread play function
displaySec = (categorys = " ") => {
presenceData.details = `Viewing${categorys}discussion thread`;
};
Expand Down Expand Up @@ -279,8 +277,8 @@ presence.on("UpdateData", async () => {

if (
pathSegments[2] === "writer" &&
document.URL.includes(document.URL.split("/")[5]) &&
document.URL.split("/")[5].split(".")[0] === "view"
document.location.href.includes(document.location.href.split("/")[5]) &&
document.location.href.split("/")[5].split(".")[0] === "view"
) {
const novelCoverElement = document.querySelector("div.novel-cover-img");
if (novelCoverElement) {
Expand Down

0 comments on commit 64c3430

Please sign in to comment.