Skip to content

Enhanced ChatGPT Clone: Features Agents, MCP, Skills, DeepSeek, Anthropic, AWS, OpenAI, Responses API, Azure, Groq, o1, GPT-5, Mistral, OpenRouter, Vertex AI, Gemini, Artifacts, AI model switching, message search, Code Interpreter, langchain, DALL-E-3, OpenAPI Actions, Functions, Secure Multi-User Auth, Presets, open-source for self-hosting. Active

⚡ fix(staticCache): NODE_ENV check

Danny Avila45479d468e20
diff --git a/api/server/utils/staticCache.js b/api/server/utils/staticCache.js
index 79b98dd173..65e7bbc58c 100644
--- a/api/server/utils/staticCache.js
+++ b/api/server/utils/staticCache.js
@@ -8,7 +8,7 @@ const maxAge = process.env.STATIC_CACHE_MAX_AGE || oneWeekInSeconds * 4;
const staticCache = (staticPath) =>
express.static(staticPath, {
setHeaders: (res) => {
- if (process.env.NODE_ENV.toLowerCase() !== 'production') {
+ if (process.env.NODE_ENV?.toLowerCase() !== 'production') {
return;
}