diff --git a/main.go b/main.go index 000acb6..7cef2c7 100644 --- a/main.go +++ b/main.go @@ -859,19 +859,6 @@ func main() { w.Header().Set("Content-Type", "application/json") http.ServeFile(w, r, filepath.Join(dataDir, LinksFile)) }) - http.HandleFunc("/fetchLink", func(w http.ResponseWriter, r *http.Request) { - link := r.URL.Query().Get("url") - u, err := url.Parse(link) - if err != nil { - http.Error(w, err.Error(), 400) - return - } - var response LinkResponse - response.Success = 1 - response.Link = u.String() - response.Meta.Title = "Test" - json.NewEncoder(w).Encode(response) - }) http.Handle("/search/", sh) http.Handle("/public/", http.StripPrefix("/public/", http.FileServer(http.Dir("./dist")))) http.Handle("/save/", &saveHandler{})