feat: some stuff?
All checks were successful
Build and Push Server / build-and-push (push) Successful in 4m19s
All checks were successful
Build and Push Server / build-and-push (push) Successful in 4m19s
This commit is contained in:
@@ -35,12 +35,13 @@ func main() {
|
||||
absPlaygroundRoot, err := filepath.Abs(*playgroundRoot)
|
||||
must(err)
|
||||
info, err := os.Stat(absPlaygroundRoot)
|
||||
must(err)
|
||||
if !info.IsDir() {
|
||||
log.Fatalf("playground-root %s is not a directory", *playgroundRoot)
|
||||
if err == nil {
|
||||
if !info.IsDir() {
|
||||
log.Fatalf("playground-root %s is not a directory", *playgroundRoot)
|
||||
}
|
||||
log.Printf("serving playground from %s", absPlaygroundRoot)
|
||||
http.Handle("/_playground/", http.StripPrefix("/_playground/", http.FileServer(http.Dir(absPlaygroundRoot))))
|
||||
}
|
||||
log.Printf("serving playground from %s", absPlaygroundRoot)
|
||||
http.Handle("/_playground/", http.StripPrefix("/_playground/", http.FileServer(http.Dir(absPlaygroundRoot))))
|
||||
}
|
||||
|
||||
if len(roots) == 0 {
|
||||
|
||||
Reference in New Issue
Block a user