mirror of
https://github.com/Auties00/Reboot-Launcher.git
synced 2026-01-13 03:02:22 +01:00
<feat: New project structure>
<feat: New release>
This commit is contained in:
22
dependencies/lawin/structure/privacy.js
vendored
Normal file
22
dependencies/lawin/structure/privacy.js
vendored
Normal file
@@ -0,0 +1,22 @@
|
||||
const Express = require("express");
|
||||
const express = Express.Router();
|
||||
const fs = require("fs");
|
||||
const privacy = require("./../responses/privacy.json");
|
||||
|
||||
express.get("/fortnite/api/game/v2/privacy/account/:accountId", async (req, res) => {
|
||||
privacy.accountId = req.params.accountId;
|
||||
|
||||
res.json(privacy);
|
||||
})
|
||||
|
||||
express.post("/fortnite/api/game/v2/privacy/account/:accountId", async (req, res) => {
|
||||
privacy.accountId = req.params.accountId;
|
||||
privacy.optOutOfPublicLeaderboards = req.body.optOutOfPublicLeaderboards;
|
||||
|
||||
fs.writeFileSync("./responses/privacy.json", JSON.stringify(privacy, null, 2));
|
||||
|
||||
res.json(privacy);
|
||||
res.end();
|
||||
})
|
||||
|
||||
module.exports = express;
|
||||
Reference in New Issue
Block a user