mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-06 23:00:25 +08:00
缓存策略增加“允许读取不完整的Partial Content”选项
This commit is contained in:
@@ -29,11 +29,12 @@ func FindCachePolicy(parent *actionutils.ParentAction, cachePolicyId int64) (*se
|
||||
if len(resp.HttpCachePolicyJSON) == 0 {
|
||||
return nil, errors.New("cache policy not found")
|
||||
}
|
||||
config := &serverconfigs.HTTPCachePolicy{}
|
||||
var config = &serverconfigs.HTTPCachePolicy{}
|
||||
err = json.Unmarshal(resp.HttpCachePolicyJSON, config)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return config, nil
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user