Fix API_BASE in OnlyOfficeEditor to include /api prefix
All checks were successful
Automated Container Build / build-and-push (push) Successful in 38s

This commit is contained in:
Elijah 2026-05-24 12:15:54 -07:00
parent 8b58c1d3cb
commit 8375406f9b

View file

@ -39,7 +39,7 @@ export default function OnlyOfficeEditor({ file, type, onClose }: OnlyOfficeEdit
const getApiBase = () => {
if (process.env.NEXT_PUBLIC_API_URL) return process.env.NEXT_PUBLIC_API_URL;
if (typeof window !== 'undefined') return window.location.origin;
if (typeof window !== 'undefined') return `${window.location.origin}/api`;
return 'http://localhost:8080';
};