refac: prompt endpoints

This commit is contained in:
Timothy Jaeryang Baek committed 2026-01-24 03:08:48 +04:00
1 parent dff0141160
commit 5ad593e465
6 files changed
+172 -114

No files matched your search

+2 -2
View File
@@ -9,7 +9,7 @@
import {
createNewPrompt,
deletePromptByCommand,
deletePromptById,
getPrompts,
getPromptList
} from '$lib/apis/prompts';
@@ -121,7 +121,7 @@
const deleteHandler = async (prompt) => {
const command = prompt.command;
const res = await deletePromptByCommand(localStorage.token, command).catch((err) => {
const res = await deletePromptById(localStorage.token, prompt.id).catch((err) => {
toast.error(err);
return null;
});