gitlab.com/evatix-go/core@v1.3.55/coreutils/stringutil/IsAnyEndsWith.go (about) 1 package stringutil 2 3 func IsAnyEndsWith( 4 content string, 5 isIgnoreCase bool, 6 endsWithTerms ...string, 7 ) bool { 8 if len(content) > 0 && len(endsWithTerms) == 0 { 9 return false 10 } 11 12 if len(content) == 0 && len(endsWithTerms) == 0 { 13 return true 14 } 15 16 for _, term := range endsWithTerms { 17 if IsEndsWith( 18 content, 19 term, 20 isIgnoreCase) { 21 return true 22 } 23 } 24 25 return false 26 }