Update page.tsx
This commit is contained in:
parent
5c459b1fff
commit
8513b8c032
@ -36,7 +36,7 @@ const CategoryView = () => {
|
|||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const fetchCategories = async () => {
|
const fetchCategories = async () => {
|
||||||
try {
|
try {
|
||||||
const basePath = process.env.NODE_ENV === "production" ? "/ProxmoxVE" : "";
|
const basePath = process.env.NODE_ENV === "production" ? "/ProxmoxVED" : "";
|
||||||
const response = await fetch(`${basePath}/api/categories`);
|
const response = await fetch(`${basePath}/api/categories`);
|
||||||
if (!response.ok) {
|
if (!response.ok) {
|
||||||
throw new Error("Failed to fetch categories");
|
throw new Error("Failed to fetch categories");
|
||||||
|
Loading…
x
Reference in New Issue
Block a user