Moved common HTTP body fetch code into a shared helper function.

This commit is contained in:
2026-01-15 08:58:56 -06:00
parent b21ed856e9
commit e28ff49201
6 changed files with 277 additions and 74 deletions

View File

@@ -1,4 +1,3 @@
// FILE: ./internal/normalizers/common/payload.go
package common
import (
@@ -8,7 +7,7 @@ import (
"gitea.maximumdirect.net/ejr/feedkit/event"
)
// PayloadBytes extracts a JSON-ish payload into bytes suitable for json.Unmarshal.
// PayloadBytes extracts a JSON payload into bytes suitable for json.Unmarshal.
//
// Supported payload shapes (weatherfeeder convention):
// - json.RawMessage (recommended for raw events)