()
| 203 | } |
| 204 | |
| 205 | const _onDeleteChart = () => { |
| 206 | setDeleteModal(false); |
| 207 | setChartLoading(true); |
| 208 | dispatch(removeChart({ |
| 209 | project_id: params.projectId, |
| 210 | chart_id: chart.id, |
| 211 | })) |
| 212 | .then((response) => { |
| 213 | if (response?.error) { |
| 214 | toast.error("Error deleting the widget"); |
| 215 | } |
| 216 | |
| 217 | setChartLoading(false); |
| 218 | }) |
| 219 | .catch(() => { |
| 220 | toast.error("Error deleting the widget"); |
| 221 | setChartLoading(false); |
| 222 | }); |
| 223 | } |
| 224 | |
| 225 | const _onSaveContent = () => { |
| 226 | setChartLoading(true); |
nothing calls this directly
no test coverage detected