From ca118681c0b2887610aefd7dc81c1ee7d7e73e06 Mon Sep 17 00:00:00 2001 From: Adnan Maolood Date: Sat, 24 Oct 2020 15:29:12 -0400 Subject: [PATCH] Update documentation --- fs.go | 4 ++-- server.go | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/fs.go b/fs.go index 9ea375c..cafd207 100644 --- a/fs.go +++ b/fs.go @@ -14,8 +14,8 @@ func init() { mime.AddExtensionType(".gemini", "text/gemini") } -// FileServer takes a filesystem and returns a Handler which uses that filesystem. -// The returned Handler sanitizes paths before handling them. +// FileServer takes a filesystem and returns a Responder which uses that filesystem. +// The returned Responder sanitizes paths before handling them. func FileServer(fsys FS) Responder { return fsHandler{fsys} } diff --git a/server.go b/server.go index e692db0..5e649d8 100644 --- a/server.go +++ b/server.go @@ -321,7 +321,7 @@ func Certificate(w *ResponseWriter, r *Request) (*x509.Certificate, bool) { return r.TLS.PeerCertificates[0], true } -// ResponderFunc is a wrapper around a bare function that implements Handler. +// ResponderFunc is a wrapper around a bare function that implements Responder. type ResponderFunc func(*ResponseWriter, *Request) func (f ResponderFunc) Respond(w *ResponseWriter, r *Request) {