debian-forge-composer/vendor/github.com/speakeasy-api/openapi-overlay/pkg/overlay/utils.go
Sanne Raymaekers b2700903ae go.mod: bump github.com/getkin/kin-openapi to v0.131.0
As deepmap/oapi-codegen didn't work with this newer version, upgrade to
oapi-codegen/oapi-codegen v2.

Mitigating CVE-2025-30153
2025-03-26 11:13:14 +01:00

19 lines
342 B
Go

package overlay
import (
"fmt"
"gopkg.in/yaml.v3"
)
func NewTargetSelector(path, method string) string {
return fmt.Sprintf(`$["paths"]["%s"]["%s"]`, path, method)
}
func NewUpdateAction(path, method string, update yaml.Node) Action {
target := NewTargetSelector(path, method)
return Action{
Target: target,
Update: update,
}
}