mirror of
https://github.com/willnorris/imageproxy.git
synced 2026-04-30 07:16:24 +02:00
minor cleanup of error messages
- used same string for logging and error response to ensure they stay in sync - pass through any http error status codes from remote URLs
This commit is contained in:
parent
8ada90ffd2
commit
2dd79ebd20
2 changed files with 13 additions and 8 deletions
2
data.go
2
data.go
|
|
@ -154,7 +154,7 @@ func NewRequest(r *http.Request) (*Request, error) {
|
|||
}
|
||||
|
||||
if req.URL.Scheme != "http" && req.URL.Scheme != "https" {
|
||||
return nil, URLError{"remote URL must have http or https URL", r.URL}
|
||||
return nil, URLError{"remote URL must have http or https scheme", r.URL}
|
||||
}
|
||||
|
||||
// query string is always part of the remote URL
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue