dkl9 commited on 2025-209 19:24:00
Showing 1 changed files, with 3 additions and 2 deletions.
| ... | ... |
@@ -7,11 +7,12 @@ const allTokens = [...allowed.terminals, ...allowed.unary, ...allowed.binary]; |
| 7 | 7 |
const tl = 5; |
| 8 | 8 |
let target; |
| 9 | 9 |
let puzzleNum; |
| 10 |
-switch (window.location.hostname) {
|
|
| 10 |
+const host = window.location.hostname; |
|
| 11 |
+switch (host) {
|
|
| 11 | 12 |
case "dkl9.net": |
| 12 | 13 |
case "www.dkl9.net": |
| 13 | 14 |
(async () => {
|
| 14 |
- const r = await fetch("https://dkl9.net/cgi-bin/fps_curr", { redirect: "follow" });
|
|
| 15 |
+ const r = await fetch(`https://${host}/cgi-bin/fps_curr`, { redirect: "follow" });
|
|
| 15 | 16 |
puzzleNum = parseInt(r.url.match(/n=(\d+)/)[1]); |
| 16 | 17 |
target = (await r.text()).trim().split(" ");
|
| 17 | 18 |
window.dispatchEvent(new Event("targetReady"));
|
| 18 | 19 |