DarthSim 1 年之前
父节点
当前提交
b90f73c4b5
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 1 1
      processing/prepare.go
  2. 1 1
      processing/trim.go

+ 1 - 1
processing/prepare.go

@@ -168,7 +168,7 @@ func prepare(pctx *pipelineContext, img *vips.Image, po *options.ProcessingOptio
 
 
 	pctx.wscale, pctx.hscale, pctx.dprScale = calcScale(widthToScale, heightToScale, po, pctx.imgtype)
 	pctx.wscale, pctx.hscale, pctx.dprScale = calcScale(widthToScale, heightToScale, po, pctx.imgtype)
 
 
-	// The size of a vector image are not checked during download, yet it can be very large.
+	// The size of a vector image is not checked during download, yet it can be very large.
 	// So we should scale it down to the maximum allowed resolution
 	// So we should scale it down to the maximum allowed resolution
 	if !pctx.trimmed && imgdata != nil && imgdata.Type.IsVector() && !po.Enlarge {
 	if !pctx.trimmed && imgdata != nil && imgdata.Type.IsVector() && !po.Enlarge {
 		resolution := imath.Round((float64(img.Width()*img.Height()) * pctx.wscale * pctx.hscale))
 		resolution := imath.Round((float64(img.Width()*img.Height()) * pctx.wscale * pctx.hscale))

+ 1 - 1
processing/trim.go

@@ -13,7 +13,7 @@ func trim(pctx *pipelineContext, img *vips.Image, po *options.ProcessingOptions,
 		return nil
 		return nil
 	}
 	}
 
 
-	// The size of a vector image are not checked during download, yet it can be very large.
+	// The size of a vector image is not checked during download, yet it can be very large.
 	// So we should scale it down to the maximum allowed resolution
 	// So we should scale it down to the maximum allowed resolution
 	if imgdata != nil && imgdata.Type.IsVector() {
 	if imgdata != nil && imgdata.Type.IsVector() {
 		if resolution := img.Width() * img.Height(); resolution > po.SecurityOptions.MaxSrcResolution {
 		if resolution := img.Width() * img.Height(); resolution > po.SecurityOptions.MaxSrcResolution {