Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
MaddyUnderStars committed Sep 22, 2023
1 parent d5ffcb9 commit 0e059f1
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 19 deletions.
7 changes: 5 additions & 2 deletions missing.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"missing": 462,
"missing": 465,
"spacebar": 154,
"discord": 593,
"discord": 596,
"routes": [
"/:id/:id/update-gaming-stats",
"/:id/force-send-prompt",
Expand Down Expand Up @@ -140,6 +140,7 @@
"/emojis/:id/source",
"/entitlements/gift-codes/:id",
"/entitlements/gift-codes/:id/redeem",
"/entitlements/partner-promotions/:id",
"/family-center/:id/activity",
"/family-center/@me",
"/family-center/@me/link-code",
Expand Down Expand Up @@ -388,6 +389,8 @@
"/users/@me/billing/subscriptions/:id/invoices/:id/pay",
"/users/@me/billing/subscriptions/:id/preview",
"/users/@me/billing/subscriptions/preview",
"/users/@me/billing/user-offer",
"/users/@me/billing/user-offer/ack",
"/users/@me/billing/user-trial-offer",
"/users/@me/billing/user-trial-offer/:id/ack",
"/users/@me/burst-credits",
Expand Down
10 changes: 5 additions & 5 deletions src/index.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
import fetch from "node-fetch";
import * as meriyah from "meriyah";
import { generate } from "astring";
import estraverse from "estraverse";
import ESTree from "estree";
import { generate } from "astring";
import fs from "fs";
import { traverse } from "estree-toolkit";
import fs from "fs";
import * as meriyah from "meriyah";
import fetch from "node-fetch";

const JAVASCRIPT_ENVIRONMENT = fs.readFileSync("./src/template.js").toString();

Expand Down Expand Up @@ -49,7 +49,7 @@ const findClientRoutes = (source: string): string[] => {
) {
// this is our routes list
const generated = generate(node);
out = JAVASCRIPT_ENVIRONMENT.replace("// --- GENERATED_CODE_MARKER ---", generated);
out = JAVASCRIPT_ENVIRONMENT.replace("undefined;// --- GENERATED_CODE_MARKER ---", generated);
return estraverse.VisitorOption.Break;
}
},
Expand Down
24 changes: 12 additions & 12 deletions src/template.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
var pe;
(function (pe) {
pe["JOIN"] = "JOIN";
pe["LISTEN"] = "LISTEN";
pe["WATCH"] = "WATCH";
pe["JOIN_REQUEST"] = "JOIN_REQUEST";
pe["JOIN"] = "JOIN";
pe["LISTEN"] = "LISTEN";
pe["WATCH"] = "WATCH";
pe["JOIN_REQUEST"] = "JOIN_REQUEST";
})(pe || (pe = {}));

var DEVICES;
(function (DEVICES) {
DEVICES["MOBILE"] = "mobile";
DEVICES["DESKTOP"] = "desktop";
DEVICES["WEB"] = "web";
DEVICES["DEVICE_CODE"] = "device_code";
DEVICES["MOBILE"] = "mobile";
DEVICES["DESKTOP"] = "desktop";
DEVICES["WEB"] = "web";
DEVICES["DEVICE_CODE"] = "device_code";
})(DEVICES || (DEVICES = {}));
const P = {};
P.g = DEVICES;
const x = {};
x.g = DEVICES;

// Some application ID, was 1096190356233670716 on 20/06/2023
const Oe = ":id";
Expand All @@ -23,9 +23,9 @@ const window = {
GLOBAL_ENV: {
WEBAPP_ENDPOINT: "webapp://"
}
}
};

const routes = // --- GENERATED_CODE_MARKER ---
const routes = undefined;// --- GENERATED_CODE_MARKER ---

// we're inside an eval, so this code is what is implicitly returned
Object.values(routes).map((route) => {
Expand Down

0 comments on commit 0e059f1

Please sign in to comment.