Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
HybridFNBR committed Mar 30, 2024
1 parent a41525b commit 0d30e55
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
9 changes: 5 additions & 4 deletions api/controllers/ApiController.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,20 +76,21 @@ module.exports = {
res.sendFile(path.join(__dirname, '../../LauncherAssets/Neonite.chunk'));
},

ias: function (req, res) {
const response = axios.get(`https://epicgames-download1.akamaized.net${req.originalUrl}`, {
ias: async function (req, res) {
const response = await axios.get(`https://epicgames-download1.akamaized.net${req.originalUrl}`, {
responseType: 'stream'
});
res.set({
'Content-Type': response.headers['content-type'],
'Content-Length': response.headers['content-length']
});
response.data.pipe(res);


},

iasChunks: function(req, res){
const response = axios.get(`https://epicgames-download1.akamaized.net${req.originalUrl}`, {
iasChunks: async function(req, res){
const response = await axios.get(`https://epicgames-download1.akamaized.net${req.originalUrl}`, {
responseType: 'stream'
});
res.set({
Expand Down
2 changes: 1 addition & 1 deletion config/http.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ module.exports.http = {
const endTime = new Date();
const responseTime = endTime - startTime;

if (req.originalUrl === "/fortnite/api/calendar/v1/timeline" || req.originalUrl.match(/^\/ias\/fortnite\//)) {
if (req.originalUrl === "/fortnite/api/calendar/v1/timeline") {
}
else
{
Expand Down

0 comments on commit 0d30e55

Please sign in to comment.