We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 642f8b1 commit b20972dCopy full SHA for b20972d
src/util/api.ts
@@ -1,6 +1,8 @@
1
import { Packr, Unpackr, addExtension } from "msgpackr";
2
import { APIResponse } from "./types";
3
4
+const cacheSessionID = `SESS-${Math.floor(Math.random() * Number.MAX_SAFE_INTEGER)}`;
5
+
6
const cache: Map<string, { expire: number; data: any }> = new Map();
7
8
addExtension({
@@ -68,6 +70,7 @@ export default async function (
68
70
69
71
let headers: any = {
72
Accept: "application/vnd.osk.theorypack",
73
+ "X-Session-ID": cacheSessionID,
74
...headers_,
75
};
76
0 commit comments