serverAddrToHost loosely converts http.Server.Addr string into a host to print.
(addr string)
| 315 | |
| 316 | // serverAddrToHost loosely converts http.Server.Addr string into a host to print. |
| 317 | func serverAddrToHost(addr string) string { |
| 318 | if addr == "" || strings.HasSuffix(addr, ":http") || strings.HasSuffix(addr, ":https") { |
| 319 | return "127.0.0.1" |
| 320 | } |
| 321 | return addr |
| 322 | } |
| 323 | |
| 324 | type serverErrorLogWriter struct { |
| 325 | app core.App |
no outgoing calls
no test coverage detected
searching dependent graphs…