Skip to content

Commit

Permalink
fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
allnash committed Oct 31, 2024
1 parent aadf961 commit aed67db
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions fast-server/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ func (s *Server) setupRoutes() {
})

// Root handler
s.echo.GET("/", func(c echo.Context) error {
s.echo.Any("/", func(c echo.Context) error {
domain := c.Get("domain").(config.Domain)
switch domain.Type {
case "proxy":
Expand All @@ -172,7 +172,7 @@ func (s *Server) setupRoutes() {
})

// Catch-all handler
s.echo.GET("/*", func(c echo.Context) error {
s.echo.Any("/*", func(c echo.Context) error {
domain := c.Get("domain").(config.Domain)
switch domain.Type {
case "proxy":
Expand All @@ -183,6 +183,7 @@ func (s *Server) setupRoutes() {
return handlers.ServeIndexOrFile(c, domain.PublicDir, c.Request().URL.Path)
}
})

}

func (s *Server) setupTLSConfig() (*tls.Config, error) {
Expand Down

0 comments on commit aed67db

Please sign in to comment.