mirror of
https://github.com/DerTyp7/teamspeak-obs-overlay.git
synced 2025-10-29 04:42:08 +01:00
fix url generation for gh pages
This commit is contained in:
@@ -19,12 +19,18 @@ export default function Generator() {
|
||||
|
||||
// Function to generate the output URL
|
||||
function generateUrl() {
|
||||
const url = new URL(window.location.href.replace("/#/generate", ""));
|
||||
const url = new URL(window.location.href);
|
||||
url.hash = "";
|
||||
|
||||
url.searchParams.set("remoteAppPort", remoteAppPort.toString());
|
||||
url.searchParams.set("showChannelName", showChannelName.toString());
|
||||
url.searchParams.set("hideNonTalking", hideNonTalking.toString());
|
||||
url.searchParams.set("clientLimit", clientLimit.toString());
|
||||
|
||||
if (url.hostname === "dertyp7.github.io") {
|
||||
url.pathname = url.pathname + "ts5-obs-overlay/";
|
||||
}
|
||||
|
||||
setOutputUrl(url.toString());
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user