mirror of
https://github.com/AutoMaker-Org/automaker.git
synced 2026-02-02 20:43:36 +00:00
fix: address pr comments
This commit is contained in:
@@ -14,7 +14,7 @@ import {
|
||||
PanelBottomClose,
|
||||
} from 'lucide-react';
|
||||
import { cn } from '@/lib/utils';
|
||||
import { apiPost, apiPut, apiDelete } from '@/lib/api-fetch';
|
||||
import { apiGet, apiPut, apiDelete } from '@/lib/api-fetch';
|
||||
import { toast } from 'sonner';
|
||||
import { useAppStore } from '@/store/app-store';
|
||||
|
||||
@@ -77,9 +77,9 @@ export function WorktreesSection({ useWorktrees, onUseWorktreesChange }: Worktre
|
||||
const loadInitScript = async () => {
|
||||
setIsLoading(true);
|
||||
try {
|
||||
const response = await apiPost<InitScriptResponse>('/api/worktree/init-script', {
|
||||
projectPath: currentProject.path,
|
||||
});
|
||||
const response = await apiGet<InitScriptResponse>(
|
||||
`/api/worktree/init-script?projectPath=${encodeURIComponent(currentProject.path)}`
|
||||
);
|
||||
if (response.success) {
|
||||
const content = response.content || '';
|
||||
setScriptContent(content);
|
||||
|
||||
Reference in New Issue
Block a user