Skip to content

Commit 4d46126

Browse files
committed
fix prod backend url
1 parent 3f472f4 commit 4d46126

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

frontend/src/constants/constants.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,9 @@ export const initialItems = [
1111
})),
1212
];
1313

14-
export const BACKEND_URL = import.meta.env.VITE_BACKEND_URL || 'http://localhost:5000';
14+
export const BACKEND_URL = import.meta.env.VITE_BACKEND_URL || (
15+
import.meta.env.MODE === 'production' ? '' : 'http://localhost:5000'
16+
);
1517

1618
export const FIFTEEN_MIN_IN_MS = 900000;
1719
export const TWO_MIN_IN_MS = 120000;

0 commit comments

Comments
 (0)