mirror of
https://github.com/octoleo/restic.git
synced 2024-11-29 16:23:59 +00:00
Store reference to reject function for insensitive pattern rejection
This commit is contained in:
parent
deedc38129
commit
cdc287a7f6
@ -93,8 +93,10 @@ func rejectByInsensitivePattern(patterns []string) RejectByNameFunc {
|
|||||||
for index, path := range patterns {
|
for index, path := range patterns {
|
||||||
patterns[index] = strings.ToLower(path)
|
patterns[index] = strings.ToLower(path)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
rejFunc := rejectByPattern(patterns)
|
||||||
return func(item string) bool {
|
return func(item string) bool {
|
||||||
return rejectByPattern(patterns)(strings.ToLower(item))
|
return rejFunc(strings.ToLower(item))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user