(filename)
| 202 | } |
| 203 | |
| 204 | export async function deleteDocument(filename) { |
| 205 | const res = await fetch(`${API_BASE}/documents/delete`, { |
| 206 | method: 'POST', |
| 207 | headers: getHeaders(), |
| 208 | body: JSON.stringify({ filename }), |
| 209 | }); |
| 210 | if (!res.ok) throw new Error('Failed to delete document'); |
| 211 | return res.json(); |
| 212 | } |
| 213 | |
| 214 | // Feedback |
| 215 | export async function getFeedback() { |
no test coverage detected