mirror of https://github.com/k3s-io/k3s
Merge pull request #48698 from sakeven/remove_mime
Automatic merge from submit-queue
remove svg mime type extension
Signed-off-by: sakeven <jc5930@sina.cn>
**What this PR does / why we need it**:
I found that [kubernetes requires go version 1.6 or greater](https://github.com/kubernetes/kubernetes/blob/master/hack/lib/golang.sh#L335).
While the [commit](21e47d831b
) which adds "image/svg+xml" type for extension ".svg", has been merged to go from version 1.5 to 1.9beta.
So it's safe to remove code ```mime.AddExtensionType(".svg", "image/svg+xml")```.
**Special notes for your reviewer**:
**Release note**:
```
NONE
```
pull/6/head
commit
69dff8b943
|
@ -18,7 +18,6 @@ package server
|
|||
|
||||
import (
|
||||
"fmt"
|
||||
"mime"
|
||||
"net/http"
|
||||
"strings"
|
||||
"sync"
|
||||
|
@ -223,13 +222,6 @@ func (s emptyDelegate) OpenAPISpec() *spec.Swagger {
|
|||
return nil
|
||||
}
|
||||
|
||||
func init() {
|
||||
// Send correct mime type for .svg files.
|
||||
// TODO: remove when https://github.com/golang/go/commit/21e47d831bafb59f22b1ea8098f709677ec8ce33
|
||||
// makes it into all of our supported go versions (only in v1.7.1 now).
|
||||
mime.AddExtensionType(".svg", "image/svg+xml")
|
||||
}
|
||||
|
||||
// RequestContextMapper is exposed so that third party resource storage can be build in a different location.
|
||||
// TODO refactor third party resource storage
|
||||
func (s *GenericAPIServer) RequestContextMapper() apirequest.RequestContextMapper {
|
||||
|
|
Loading…
Reference in New Issue