This commit is contained in:
2025-10-19 18:27:09 +02:00
parent fd4ad12e44
commit 77e0343330
6 changed files with 206 additions and 336 deletions

View File

@@ -167,7 +167,6 @@ func (s *HTTPServer) setupRoutes() {
api.HandleFunc("/watchlist/spots", s.getWatchlistSpotsWithStatus).Methods("GET", "OPTIONS")
api.HandleFunc("/watchlist/add", s.addToWatchlist).Methods("POST", "OPTIONS")
api.HandleFunc("/watchlist/remove", s.removeFromWatchlist).Methods("DELETE", "OPTIONS")
api.HandleFunc("/watchlist/update-notes", s.updateWatchlistNotes).Methods("POST", "OPTIONS")
api.HandleFunc("/watchlist/update-sound", s.updateWatchlistSound).Methods("POST", "OPTIONS")
api.HandleFunc("/stats/spots", s.getSpotProcessingStats).Methods("GET", "OPTIONS")
api.HandleFunc("/logs", s.getLogs).Methods("GET", "OPTIONS")
@@ -715,11 +714,6 @@ func (s *HTTPServer) updateWatchlistNotes(w http.ResponseWriter, r *http.Request
return
}
if err := s.Watchlist.UpdateNotes(req.Callsign, req.Notes); err != nil {
s.sendJSON(w, APIResponse{Success: false, Error: err.Error()})
return
}
s.Log.Debugf("Updated notes for %s", req.Callsign)
// Broadcast updated watchlist to all clients