(patterns []etscore.KeyPattern)
| 143 | } |
| 144 | |
| 145 | func cloneKeyPatterns(patterns []etscore.KeyPattern) []etscore.KeyPattern { |
| 146 | if len(patterns) == 0 { |
| 147 | return nil |
| 148 | } |
| 149 | cloned := make([]etscore.KeyPattern, len(patterns)) |
| 150 | for i, pattern := range patterns { |
| 151 | cloned[i] = etscore.KeyPattern{ |
| 152 | Target: pattern.Target, |
| 153 | Pattern: pattern.Pattern, |
| 154 | SkipLeadingPath: append([]string(nil), pattern.SkipLeadingPath...), |
| 155 | } |
| 156 | } |
| 157 | return cloned |
| 158 | } |
no outgoing calls
no test coverage detected