func (s fileServer) ServeHTTP(res http.ResponseWriter, req *http.Request) {
	path := strings.Split(strings.TrimPrefix(req.URL.EscapedPath(), "/"), "/")
	if len(path) != 3 || path[0] != "files" {
		http.Error(res, fmt.Sprintf("unable to parse files uri: %v", req.URL.EscapedPath()), http.StatusBadRequest)
		return
	}
	service, err := url.PathUnescape(path[1])
	if err != nil {
		http.Error(res, fmt.Sprintf("unable to parse path component [%v]: %v", path[1], err), http.StatusBadRequest)
		return
	}
	name, err := url.PathUnescape(path[2])
	if err != nil {
		http.Error(res, fmt.Sprintf("unable to parse path component [%v]: %v", path[2], err), http.StatusBadRequest)
		return
	}
	ctx := req.Context()
	data, modtime, err := s.fs.ReadFile(ctx, service, name)
	if err != nil {
		if s.fs.IsNotFound(err) {
			http.Error(res, "file not found", http.StatusNotFound)
			return
		}
		http.Error(res, fmt.Sprintf("internal error: %v", err), http.StatusInternalServerError)
		return
	}
	http.ServeContent(res, req, name, modtime, data)
	data.Close()
}
ServeHTTP implements http.Handler
package https
import (
	"fmt"
	"net/http"
	"net/url"
	"strings"
)
type fileServer struct {
	*Communicator
}