mirror of
https://github.com/StackExchange/dnscontrol.git
synced 2024-05-11 05:55:12 +00:00
migrate code for github
This commit is contained in:
30
vendor/github.com/aws/aws-sdk-go/service/route53/customizations.go
generated
vendored
Normal file
30
vendor/github.com/aws/aws-sdk-go/service/route53/customizations.go
generated
vendored
Normal file
@ -0,0 +1,30 @@
|
||||
package route53
|
||||
|
||||
import (
|
||||
"regexp"
|
||||
|
||||
"github.com/aws/aws-sdk-go/aws/client"
|
||||
"github.com/aws/aws-sdk-go/aws/request"
|
||||
"github.com/aws/aws-sdk-go/private/protocol/restxml"
|
||||
)
|
||||
|
||||
func init() {
|
||||
initClient = func(c *client.Client) {
|
||||
c.Handlers.Build.PushBack(sanitizeURL)
|
||||
}
|
||||
|
||||
initRequest = func(r *request.Request) {
|
||||
switch r.Operation.Name {
|
||||
case opChangeResourceRecordSets:
|
||||
r.Handlers.UnmarshalError.Remove(restxml.UnmarshalErrorHandler)
|
||||
r.Handlers.UnmarshalError.PushBack(unmarshalChangeResourceRecordSetsError)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
var reSanitizeURL = regexp.MustCompile(`\/%2F\w+%2F`)
|
||||
|
||||
func sanitizeURL(r *request.Request) {
|
||||
r.HTTPRequest.URL.Opaque =
|
||||
reSanitizeURL.ReplaceAllString(r.HTTPRequest.URL.Opaque, "/")
|
||||
}
|
Reference in New Issue
Block a user