From c890dad54f9852615062bea7e95dd5cfab1f25a1 Mon Sep 17 00:00:00 2001 From: Anton Vakhrushev Date: Fri, 9 Jan 2026 11:48:49 +0300 Subject: [PATCH] fix lines in list endpoint --- .gitignore | 3 +++ main.go | 3 ++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 9f11b75..24a8536 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,4 @@ .idea/ +cache/ + +/config.toml diff --git a/main.go b/main.go index 7805f1c..0c39a4a 100644 --- a/main.go +++ b/main.go @@ -147,7 +147,7 @@ func main() { w.Header().Set("Content-Type", "text/plain; charset=utf-8") for i, link := range links { if i > 0 { - _, _ = w.Write([]byte("\n")) + _, _ = w.Write([]byte("\n\n")) } _, _ = w.Write([]byte(link)) } @@ -185,6 +185,7 @@ func pollSource(ctx context.Context, source string, interval time.Duration, cach for { select { case <-ctx.Done(): + log.Printf("poller shutdown") return case <-ticker.C: runOnce(ctx, source, cacheDir, agg, client)