优化代码

This commit is contained in:
GoEdgeLab
2023-08-08 12:09:20 +08:00
parent d17a7cc4eb
commit 9ed5fab2a8
4 changed files with 12 additions and 2 deletions

View File

@@ -425,6 +425,9 @@ func (this *HTTPWebService) UpdateHTTPWebPages(ctx context.Context, req *pb.Upda
if len(req.PagesJSON) > 0 {
var pages = []*serverconfigs.HTTPPageConfig{}
err = json.Unmarshal(req.PagesJSON, &pages)
if err != nil {
return nil, err
}
for _, page := range pages {
err = page.Init()