internal

package
v1.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 8, 2026 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddHeaders added in v1.3.0

func AddHeaders(dst http.Header, headers []string) error

AddHeaders parses "Name: Value" entries into dst. It rejects anything net/http would refuse to send, so entries that pass here can't fail later for being malformed. Errors give the entry's position instead of its content.

func DecodeSettings

func DecodeSettings(src *map[string]any, targets ...any) error

func ValidateHTTPURL added in v1.3.0

func ValidateHTTPURL(raw string) error

ValidateHTTPURL checks a URL setting is an absolute http or https URL. Errors don't include the URL, as it may contain credentials.

func ValidateNetwork added in v1.3.0

func ValidateNetwork(network string) error

ValidateNetwork checks a network setting is one that checks can dial: tcp, or tcp4/tcp6 to force an IP version.

func WithoutURL added in v1.3.0

func WithoutURL(err error) error

WithoutURL strips the URL from a url.Error, as it may contain credentials.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL