Skip to content
Myr

Replace fmt.Errorf with no parameters with errors.New (#3747)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by Cheng · committed by GitHub · parent af3ce47 · Browse files · 1 file+1 added−1 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+1 added−1 removed

  • other:+1 added−1 removed

1 file+1 added−1 removed

modified:src/server.go+1 added-1 removed
76 unmodified lines
77 host := address.host78 port := address.port79 apiKey := os.Getenv("FZF_API_KEY")80 if !address.IsLocal() && len(apiKey) == 0 {81 return port, fmt.Errorf("FZF_API_KEY is required to allow remote access")81 return port, errors.New("FZF_API_KEY is required to allow remote access")82 }83 addrStr := fmt.Sprintf("%s:%d", host, port)84 listener, err := net.Listen("tcp", addrStr)85 if err != nil {
172 unmodified lines