mirror of
https://github.com/caddyserver/caddy.git
synced 2025-01-23 17:16:40 +01:00
Remove trailing new line for cleaner log output.
Return correct status code.
This commit is contained in:
parent
b7fd1f4e9e
commit
3966936bd6
1 changed files with 3 additions and 2 deletions
|
@ -117,10 +117,11 @@ func (h Handler) ServeHTTP(w http.ResponseWriter, r *http.Request) (int, error)
|
|||
|
||||
// FastCGI stderr outputs
|
||||
if fcgi.stderr.Len() != 0 {
|
||||
err = LogError(fcgi.stderr.String())
|
||||
// Remove trailing newline, error logger already does this.
|
||||
err = LogError(strings.TrimSuffix(fcgi.stderr.String(), "\n"))
|
||||
}
|
||||
|
||||
return 0, err
|
||||
return resp.StatusCode, err
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue