MCPcopy Create free account
hub / github.com/chainreactors/EvilProxy / normalizePluginDesiredVersion

Function normalizePluginDesiredVersion

internal/pluginhost/config.go:116–125  ·  view source on GitHub ↗
(version string)

Source from the content-addressed store, hash-verified

114}
115
116func normalizePluginDesiredVersion(version string) string {
117 version = strings.TrimSpace(version)
118 if len(version) > 1 && (version[0] == 'v' || version[0] == 'V') {
119 version = version[1:]
120 }
121 if !validPluginVersion(version) {
122 return ""
123 }
124 return version
125}
126
127func yamlScalarString(node *yaml.Node) string {
128 if node == nil || node.Kind == 0 {

Callers 3

Calls 1

validPluginVersionFunction · 0.70

Tested by

no test coverage detected