💩 Clean up server header
All checks were successful
release-nightly / build-docker (push) Successful in 1m18s

This commit is contained in:
LittleSheep 2023-12-16 12:03:25 +08:00
parent f31d35c86c
commit 79e060da5d
2 changed files with 2 additions and 4 deletions

View File

@ -1,10 +1,8 @@
package hypertext package hypertext
import ( import (
"fmt"
"time" "time"
roadsign "code.smartsheep.studio/goatworks/roadsign/pkg"
"github.com/gofiber/fiber/v2" "github.com/gofiber/fiber/v2"
"github.com/gofiber/fiber/v2/middleware/limiter" "github.com/gofiber/fiber/v2/middleware/limiter"
"github.com/gofiber/fiber/v2/middleware/logger" "github.com/gofiber/fiber/v2/middleware/logger"
@ -15,7 +13,7 @@ import (
func InitServer() *fiber.App { func InitServer() *fiber.App {
app := fiber.New(fiber.Config{ app := fiber.New(fiber.Config{
AppName: "RoadSign", AppName: "RoadSign",
ServerHeader: fmt.Sprintf("RoadSign v%s", roadsign.AppVersion), ServerHeader: "RoadSign",
DisableStartupMessage: true, DisableStartupMessage: true,
EnableIPValidation: true, EnableIPValidation: true,
Prefork: viper.GetBool("performance.prefork"), Prefork: viper.GetBool("performance.prefork"),

View File

@ -14,7 +14,7 @@ import (
func InitSideload() *fiber.App { func InitSideload() *fiber.App {
app := fiber.New(fiber.Config{ app := fiber.New(fiber.Config{
AppName: "RoadSign Sideload", AppName: "RoadSign Sideload",
ServerHeader: fmt.Sprintf("RoadSign Sideload v%s", roadsign.AppVersion), ServerHeader: "RoadSign Sideload",
DisableStartupMessage: true, DisableStartupMessage: true,
EnableIPValidation: true, EnableIPValidation: true,
EnablePrintRoutes: viper.GetBool("debug.print_routes"), EnablePrintRoutes: viper.GetBool("debug.print_routes"),