mirror of
https://github.com/Lawin0129/LawinServer.git
synced 2026-01-13 10:52:23 +01:00
Discovery Tab fix for latest
This commit is contained in:
@@ -7,9 +7,11 @@
|
||||
"results": [
|
||||
{
|
||||
"linkData": {
|
||||
"namespace": "fn",
|
||||
"mnemonic": "playlist_defaultsolo",
|
||||
"linkType": "BR:Playlist",
|
||||
"active": true,
|
||||
"disabled": false,
|
||||
"version": 95,
|
||||
"moderationStatus": "Unmoderated",
|
||||
"accountId": "epic",
|
||||
@@ -22,13 +24,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"lastVisited": null,
|
||||
"linkCode": "playlist_defaultsolo",
|
||||
"isFavorite": false
|
||||
},
|
||||
{
|
||||
"linkData": {
|
||||
"namespace": "fn",
|
||||
"mnemonic": "playlist_defaultduo",
|
||||
"linkType": "BR:Playlist",
|
||||
"active": true,
|
||||
"disabled": false,
|
||||
"version": 95,
|
||||
"moderationStatus": "Unmoderated",
|
||||
"accountId": "epic",
|
||||
@@ -41,13 +47,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"lastVisited": null,
|
||||
"linkCode": "playlist_defaultduo",
|
||||
"isFavorite": false
|
||||
},
|
||||
{
|
||||
"linkData": {
|
||||
"namespace": "fn",
|
||||
"mnemonic": "playlist_trios",
|
||||
"linkType": "BR:Playlist",
|
||||
"active": true,
|
||||
"disabled": false,
|
||||
"version": 95,
|
||||
"moderationStatus": "Unmoderated",
|
||||
"accountId": "epic",
|
||||
@@ -60,13 +70,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"lastVisited": null,
|
||||
"linkCode": "playlist_trios",
|
||||
"isFavorite": false
|
||||
},
|
||||
{
|
||||
"linkData": {
|
||||
"namespace": "fn",
|
||||
"mnemonic": "playlist_defaultsquad",
|
||||
"linkType": "BR:Playlist",
|
||||
"active": true,
|
||||
"disabled": false,
|
||||
"version": 95,
|
||||
"moderationStatus": "Unmoderated",
|
||||
"accountId": "epic",
|
||||
@@ -79,13 +93,17 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"lastVisited": null,
|
||||
"linkCode": "playlist_defaultsquad",
|
||||
"isFavorite": false
|
||||
},
|
||||
{
|
||||
"linkData": {
|
||||
"namespace": "fn",
|
||||
"mnemonic": "campaign",
|
||||
"linkType": "SubGame",
|
||||
"active": true,
|
||||
"disabled": false,
|
||||
"version": 5,
|
||||
"moderationStatus": "Unmoderated",
|
||||
"accountId": "epic",
|
||||
@@ -129,11 +147,6 @@
|
||||
"minimumNumberOfPlayers": 1,
|
||||
"joinInProgressTeam": 1
|
||||
},
|
||||
"disallowedPlatforms": [
|
||||
"IOS",
|
||||
"Android",
|
||||
"Switch"
|
||||
],
|
||||
"alt_title": {
|
||||
"de": "Rette die Welt",
|
||||
"ru": "Сражение с Бурей",
|
||||
@@ -178,6 +191,8 @@
|
||||
"introduction": "Battle to hold back the monster hordes and explore a vast, destructible world. Build huge forts, craft weapons, find loot and level up."
|
||||
}
|
||||
},
|
||||
"lastVisited": null,
|
||||
"linkCode": "campaign",
|
||||
"isFavorite": false
|
||||
}
|
||||
],
|
||||
|
||||
@@ -2,8 +2,28 @@ const Express = require("express");
|
||||
const express = Express.Router();
|
||||
const discovery = require("./../responses/discovery/discovery_frontend.json");
|
||||
|
||||
express.post("/fortnite/api/game/v2/creative/discovery/surface/*", async (req, res) => {
|
||||
express.post("*discovery/surface/*", async (req, res) => {
|
||||
res.json(discovery);
|
||||
})
|
||||
|
||||
express.post("/links/api/fn/mnemonic", async (req, res) => {
|
||||
var MnemonicArray = [];
|
||||
|
||||
for (var i in discovery.Panels[0].Pages[0].results) {
|
||||
MnemonicArray.push(discovery.Panels[0].Pages[0].results[i].linkData)
|
||||
console.log(discovery.Panels[0].Pages[0].results[i].linkData.mnemonic);
|
||||
}
|
||||
|
||||
res.json(MnemonicArray);
|
||||
})
|
||||
|
||||
express.get("/links/api/fn/mnemonic/*", async (req, res) => {
|
||||
for (var i in discovery.Panels[0].Pages[0].results) {
|
||||
console.log(discovery.Panels[0].Pages[0].results[i].linkData.mnemonic);
|
||||
if (discovery.Panels[0].Pages[0].results[i].linkData.mnemonic == req.url.split("/").slice(-1)[0]) {
|
||||
res.json(discovery.Panels[0].Pages[0].results[i].linkData);
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
module.exports = express;
|
||||
Reference in New Issue
Block a user