mirror of
https://github.com/TeaOSLab/EdgeNode.git
synced 2025-11-05 01:20:26 +08:00
只有满足缓存条件的图片内容才会被转换
This commit is contained in:
@@ -443,6 +443,11 @@ func (this *HTTPWriter) PrepareWebP(resp *http.Response, size int64) {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 只有在开启了缓存之后,才会转换,防止占用的系统资源过高
|
||||||
|
if this.req.cacheRef == nil {
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
var contentType = this.GetHeader("Content-Type")
|
var contentType = this.GetHeader("Content-Type")
|
||||||
|
|
||||||
if this.req.web != nil &&
|
if this.req.web != nil &&
|
||||||
|
|||||||
Reference in New Issue
Block a user