From 08df9258a532b653c243e077e82491dbe62ad854 Mon Sep 17 00:00:00 2001 From: Philipp Tanlak Date: Sat, 23 Sep 2023 17:41:57 +0200 Subject: refactor scraper into modules --- utils.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'utils.go') diff --git a/utils.go b/utils.go index 89ce3f1..8b52e76 100644 --- a/utils.go +++ b/utils.go @@ -26,3 +26,7 @@ func Print(v any, prefix string) string { enc.Encode(v) return prefix + strings.TrimSuffix(buf.String(), "\n") } + +func ParseOptions(opts Options, v any) { + json.Unmarshal(opts, v) +} -- cgit v1.2.3