How it works
@@ -1541,33 +1507,6 @@ WATCHLIST_HTML = r"""
}
}
- async function addAnimeToWatchlist() {
- const showId = $("watchlist-show-id").value.trim();
- const title = $("watchlist-title").value.trim();
- if (!showId || !title) {
- setNotice("Fill in the watchlist title and show ID.");
- return;
- }
- try {
- const data = await api("/api/watchlist", {
- method: "POST",
- body: JSON.stringify({
- show_id: showId,
- title,
- category: $("watchlist-category").value,
- media_type: $("watchlist-media-type").value
- })
- });
- $("watchlist-form").reset();
- $("watchlist-category").value = "watching";
- $("watchlist-media-type").value = "tv";
- setNotice(data.message || "Added to watchlist.");
- await fetchWatchlist();
- } catch (error) {
- setNotice(error.message);
- }
- }
-
async function refreshWatchlistItem(showId) {
try {
const data = await api("/api/watchlist/update-status", {