WithExcludeList returns an Option that sets the excludeList field of a config object to the given value.
(val []string)
| 26 | |
| 27 | // WithExcludeList returns an Option that sets the excludeList field of a config object to the given value. |
| 28 | func WithExcludeList(val []string) Option { |
| 29 | return optionFunc(func(c *config) { |
| 30 | // If the given value is empty, do nothing. |
| 31 | if len(val) == 0 { |
| 32 | return |
| 33 | } |
| 34 | c.excludeList = val |
| 35 | }) |
| 36 | } |
| 37 | |
| 38 | // WithEnableAmend returns an Option that sets the isAmend field of a config object to the given value. |
| 39 | func WithEnableAmend(val bool) Option { |
no test coverage detected