1
0
mirror of https://github.com/imgproxy/imgproxy.git synced 2025-12-03 23:19:17 +02:00

Merge branch 'master' into version/2.1

This commit is contained in:
DarthSim
2018-11-02 19:14:45 +06:00
3 changed files with 13 additions and 6 deletions

View File

@@ -12,7 +12,6 @@ import (
"errors"
"fmt"
"net/http"
"net/url"
"regexp"
"strconv"
"strings"
@@ -134,7 +133,6 @@ const (
var (
errInvalidURLEncoding = errors.New("Invalid url encoding")
errInvalidPath = errors.New("Invalid path")
errInvalidImageURL = errors.New("Invalid image url")
errResultingImageFormatIsNotSupported = errors.New("Resulting image format is not supported")
)
@@ -766,10 +764,6 @@ func parsePath(ctx context.Context, r *http.Request) (context.Context, error) {
return ctx, err
}
if _, err = url.ParseRequestURI(imageURL); err != nil {
return ctx, errInvalidImageURL
}
ctx = context.WithValue(ctx, imageURLCtxKey, imageURL)
ctx = context.WithValue(ctx, processingOptionsCtxKey, po)