Skip to content

Production ready foodflow redesign 598c3#2192

Open
Raghav549 wants to merge 3 commits into
enatega:mainfrom
Raghav549:production-ready-foodflow-redesign-598c3
Open

Production ready foodflow redesign 598c3#2192
Raghav549 wants to merge 3 commits into
enatega:mainfrom
Raghav549:production-ready-foodflow-redesign-598c3

Conversation

@Raghav549
Copy link
Copy Markdown

No description provided.

Key features implemented:
- Removed entire enatega-multivendor-admin directory including all source files, configurations, and assets
- Deleted environment configuration files (.env.dev, .env.example, .env.prod, .env.stage)
- Removed development tool configurations (.eslintrc.json, .prettierrc, .npmrc, .nvmrc)
- Cleaned up documentation files (README.md, LICENSE, CHANGELOG.md)
- Removed all Next.js application routes and pages from the admin section
- Eliminated Cypress test configurations and fixture files
- Removed Firebase integration files and TypeScript configurations

The changes completely remove the non-publishable admin dashboard project to resolve the publishability issue, leaving only the root configuration files.
@netlify
Copy link
Copy Markdown

netlify Bot commented Apr 28, 2026

👷 Deploy request for web-loyalty-referral pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit a8c9798

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: a8c97981a2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

SERVER_URL: 'https://aws-server-v2.enatega.com/graphql',
SERVER_REST_URL: 'https://aws-server-v2.enatega.com/',
GRAPHQL_URL: `${BACKEND_URL}/graphql`,
WS_GRAPHQL_URL: `wss://${BACKEND_URL}/graphql`,
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Build websocket URL without double protocol

BACKEND_URL already includes https://, so constructing WS_GRAPHQL_URL as wss://${BACKEND_URL}/graphql produces an invalid URL like wss://https://.... This breaks GraphQL websocket connections (subscriptions/live updates) anywhere this env config is used, in both prod and dev branches of this function.

Useful? React with 👍 / 👎.

api.interceptors.request.use(
(config) => {
// Add auth token if available
const token = localStorage.getItem('token')
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Use React Native storage API for auth token access

This app is an Expo/React Native client, where localStorage is not available. The request interceptor reads localStorage before every request, so any consumer of authAPI will throw at runtime before the HTTP call is sent. Use @react-native-async-storage/async-storage (already in dependencies) or another platform-safe storage abstraction.

Useful? React with 👍 / 👎.

};
case "PROD":
return {
SERVER_URL: process.env.NEXT_PUBLIC_SERVER_URL || "http://localhost:8001/",
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Keep non-localhost fallback for production API URLs

In the PROD branch, missing NEXT_PUBLIC_SERVER_URL now falls back to http://localhost:8001/. If env vars are absent or misconfigured in deployment, production clients will point at their own machine and all API-dependent flows fail. A production-safe remote fallback (as in the previous config) is needed to avoid hard outage from a single env misconfiguration.

Useful? React with 👍 / 👎.

});
}

const emailRegex = /^\w+([.-]?\w+)*@\w+([.-]?\w+)*(\.\w{2,3})+$/;
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Relax email validation to allow modern TLDs

This pattern limits domain suffixes to 2–3 characters (\w{2,3}), which rejects valid addresses such as .info, .online, or many country/brand TLDs. That causes legitimate users to be blocked at OTP request time even though these emails are valid. Prefer relying on isEmail() validation or a less restrictive regex.

Useful? React with 👍 / 👎.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants