summaryrefslogtreecommitdiff
path: root/pkg/api/list.go
diff options
context:
space:
mode:
authorAlexander Neonxp Kiryukhin <i@neonxp.ru>2024-10-29 01:21:05 +0300
committerAlexander Neonxp Kiryukhin <i@neonxp.ru>2024-10-29 01:21:05 +0300
commitfd4e0c3112d69061d495dfcf79f6ef62e3c6d5e6 (patch)
treefa55d6e879e3c6d85601d5c2486837f323ffd81d /pkg/api/list.go
parentb26bd10926447ed59cbf263aef087bb7c04f35eb (diff)
Начальный веб клиентHEADmaster
Diffstat (limited to 'pkg/api/list.go')
-rw-r--r--pkg/api/list.go29
1 files changed, 0 insertions, 29 deletions
diff --git a/pkg/api/list.go b/pkg/api/list.go
deleted file mode 100644
index 80a34ea..0000000
--- a/pkg/api/list.go
+++ /dev/null
@@ -1,29 +0,0 @@
-package api
-
-import (
- "fmt"
- "net/http"
- "strings"
-)
-
-func (a *API) getListHandler(w http.ResponseWriter, r *http.Request) {
- echos, err := a.idec.GetEchos()
- if err != nil {
- http.Error(w, err.Error(), http.StatusInternalServerError)
- return
- }
-
- for _, e := range echos {
- fmt.Fprintf(w, "%s:%d:%s\n", e.Name, e.Count, e.Description)
- }
-}
-
-func (a *API) getBlacklistHandler(w http.ResponseWriter, r *http.Request) {
- list, err := a.idec.GetBlacklist()
- if err != nil {
- http.Error(w, err.Error(), http.StatusInternalServerError)
- return
- }
-
- fmt.Fprint(w, strings.Join(list, "\n"))
-}