AddIgnores adds log ignore patterns to the server
(specs []string)
| 226 | |
| 227 | // AddIgnores adds log ignore patterns to the server |
| 228 | func (dd *Devd) AddIgnores(specs []string) error { |
| 229 | dd.IgnoreLogs = make([]*regexp.Regexp, 0, 0) |
| 230 | for _, expr := range specs { |
| 231 | v, err := regexp.Compile(expr) |
| 232 | if err != nil { |
| 233 | return fmt.Errorf("%s", err) |
| 234 | } |
| 235 | dd.IgnoreLogs = append(dd.IgnoreLogs, v) |
| 236 | } |
| 237 | return nil |
| 238 | } |
| 239 | |
| 240 | // HandleNotFound handles pages not found. In particular, this handler is used |
| 241 | // when we have no matching route for a request. This also means it's not |