Updates
This commit is contained in:
@@ -22,14 +22,14 @@ const requestListener = function (clientReq, clientRes) {
|
||||
if (providedSecret !== PROXY_SECRET) {
|
||||
console.warn(`Unauthorized access: Invalid secret`);
|
||||
clientRes.writeHead(403);
|
||||
clientRes.end(JSON.stringify({ error: "Forbidden: Invalid access key" }));
|
||||
clientRes.end();
|
||||
return;
|
||||
}
|
||||
|
||||
if (!GIPHY_API_KEY) {
|
||||
console.error("GIPHY_API_KEY is not configured.");
|
||||
clientRes.writeHead(500);
|
||||
clientRes.end(JSON.stringify({ error: "Server configuration error" }));
|
||||
clientRes.end();
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user