Merge: - don't load filter rules if filter is disabled

Close #879

* commit 'e2b518339fe6c14bb29008ad1638244e2f0fb3f8':
  - don't load filter rules if filter is disabled
This commit is contained in:
Simon Zolin 2019-07-15 13:17:44 +03:00
commit c81c79aad7

View file

@ -179,6 +179,9 @@ func generateServerConfig() (dnsforward.ServerConfig, error) {
Data: userFilter.Data,
})
for _, filter := range config.Filters {
if !filter.Enabled {
continue
}
filters = append(filters, dnsfilter.Filter{
ID: filter.ID,
FilePath: filter.Path(),