MCPcopy Create free account
hub / github.com/Threadfin/Threadfin / removeStringFromSlice

Function removeStringFromSlice

src/internal/imgcache/tools.go:25–34  ·  view source on GitHub ↗
(str string, slice []string)

Source from the content-addressed store, hash-verified

23}
24
25func removeStringFromSlice(str string, slice []string) []string {
26
27 var i = indexOfString(str, slice)
28
29 if i != -1 {
30 slice = append(slice[:i], slice[i+1:]...)
31 }
32
33 return slice
34}

Callers 1

NewFunction · 0.85

Calls 1

indexOfStringFunction · 0.70

Tested by

no test coverage detected