Rename Section to Crew, stage the load pipeline, dedupe lookups and token minting, drop burned tools
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
"mime"
|
||||
"net/http"
|
||||
"os"
|
||||
"path/filepath"
|
||||
"strings"
|
||||
|
||||
"heliosian/internal/auth"
|
||||
@@ -50,6 +51,13 @@ func clientID() string {
|
||||
return parsed.Web.ClientID
|
||||
}
|
||||
|
||||
type staticFiles struct{}
|
||||
|
||||
func (staticFiles) Has(key string) bool {
|
||||
_, err := os.Stat(filepath.Join("web/static", filepath.FromSlash(key)))
|
||||
return err == nil
|
||||
}
|
||||
|
||||
func noCache(next http.Handler) http.Handler {
|
||||
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Set("Cache-Control", "no-cache")
|
||||
@@ -99,7 +107,7 @@ func main() {
|
||||
}
|
||||
blobs = store
|
||||
}
|
||||
cache, err := directory.NewCache(source, geocoder, blobs)
|
||||
cache, err := directory.NewCache(source, geocoder, blobs, staticFiles{})
|
||||
if err != nil {
|
||||
log.Fatalf("[ERROR] load directory data: %v", err)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user