From d3fe828d5926dc074b43ff0fdf0de9db081df01b Mon Sep 17 00:00:00 2001 From: EwenQuim Date: Fri, 5 Apr 2024 18:19:21 +0200 Subject: [PATCH] Really mark WithPort as deprecated The "Deprecated:" string must start a paragraph! https://stackoverflow.com/questions/7849663/how-do-you-mark-code-as-deprecated-in-go --- options.go | 1 + 1 file changed, 1 insertion(+) diff --git a/options.go b/options.go index 0f2b981d..c74d4543 100644 --- a/options.go +++ b/options.go @@ -226,6 +226,7 @@ func WithDisallowUnknownFields(b bool) func(*Server) { // WithPort sets the port of the server. For example, 8080. // If not specified, the default port is 9999. // If you want to use a different address, use [WithAddr] instead. +// // Deprecated: Please use fuego.WithAddr(addr string) func WithPort(port int) func(*Server) { return func(s *Server) { s.Server.Addr = fmt.Sprintf("localhost:%d", port) }