Documentation
¶
Index ¶
Constants ¶
View Source
const UserAgent = "" /* 129-byte string literal not displayed */
Variables ¶
View Source
var ErrInvalidURL = errors.New("webhook/file: invalid URL")
Functions ¶
func ServeFile ¶ added in v0.17.1
func ServeFile(w http.ResponseWriter, r *http.Request, fs http.FileSystem, name string, redirect bool)
Types ¶
type Downloader ¶
type Downloader struct {
Root string
Options map[string]string
// contains filtered or unexported fields
}
func NewDownloader ¶
func NewDownloader(root string, client ...Client) *Downloader
func (*Downloader) Register ¶
func (d *Downloader) Register(client ...Client)
func (*Downloader) ServeHTTP ¶ added in v0.17.0
func (d *Downloader) ServeHTTP(w http.ResponseWriter, r *http.Request)
type WithUserAgent ¶ added in v0.17.0
type WithUserAgent []string
func (WithUserAgent) Hosts ¶ added in v0.17.0
func (c WithUserAgent) Hosts() []string
Click to show internal directories.
Click to hide internal directories.