adds no search result errors

This commit is contained in:
derpystuff 2022-07-13 14:03:08 +02:00
parent c09a24ce9d
commit 52d2bbbc2d
6 changed files with 10 additions and 4 deletions

View file

@ -1,6 +1,6 @@
const Hosts = Object.freeze({
prod: "https://labscore-v2.vercel.app",
local: "http://localhost:3000",
local: "http://localhost",
emoji: "https://derpystuff.gitlab.io/webstorage3/container/",
statics: "https://derpystuff.gitlab.io/webstorage4/v2/"
})

View file

@ -5,7 +5,7 @@ const { Api, Static, Hosts } = require('./endpoints')
async function request(path, type, headers, args, host) {
let timing = Date.now();
url = Api.HOST + path
if(process.env.USE_LOCAL_API) url = Hosts.local + path
if(process.env.USE_LOCAL_API) url = Hosts.local + ":" + process.env.USE_LOCAL_API + path
if(host) url = host + path
// apply default headers