fix: remove dependency on FASTAPI_URL in useTemplateLayoutsAutoSave hook for improved flexibility
This commit is contained in:
parent
fc17b25909
commit
92a583c226
1 changed files with 1 additions and 2 deletions
|
|
@ -1,7 +1,6 @@
|
|||
'use client';
|
||||
|
||||
import { useEffect, useRef, useCallback, useState } from 'react';
|
||||
import { FASTAPI_URL } from '@/constants';
|
||||
import { getHeader } from '@/app/(presentation-generator)/services/api/header';
|
||||
import { ApiResponseHandler } from '@/app/(presentation-generator)/services/api/api-error-handler';
|
||||
import { ProcessedSlide } from '@/app/custom-template/types';
|
||||
|
|
@ -72,7 +71,7 @@ export const useTemplateLayoutsAutoSave = ({
|
|||
setSaveStatus('saving');
|
||||
console.log('🔄 Auto-saving template layouts...');
|
||||
|
||||
const response = await fetch(`${FASTAPI_URL}/api/v1/ppt/template/update`, {
|
||||
const response = await fetch('/api/v1/ppt/template/update', {
|
||||
method: 'PUT',
|
||||
headers: getHeader(),
|
||||
body: JSON.stringify({
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue