dxc hace 1 año
padre
commit
2f570d2602
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      internal/logic/transcodercallbacklogic.go

+ 1 - 1
internal/logic/transcodercallbacklogic.go

@@ -33,7 +33,7 @@ func (l *TranscoderCallbackLogic) TranscoderCallback(req *types.CallbackRequest)
 	}
 	//校验req.Path是否符合url的正则格式
 	var urlRegexp = regexp.MustCompile(`^(?:(http|https|ftp):\/\/)?((|[\w-]+\.)+[a-z0-9]+)(?:(\/[^/?#]+)*)?(\?[^#]+)?(#.+)?$`)
-	if !urlRegexp.MatchString(req.Path) || urlRegexp.MatchString(req.CallbackUrl) {
+	if !urlRegexp.MatchString(req.Path) || !urlRegexp.MatchString(req.CallbackUrl) {
 		err = errors.New("path or callback_url is not url")
 		return
 	}