filtering: rewrite http
This commit is contained in:
@@ -33,6 +33,10 @@ func (d *DNSFilter) handleRewriteAdd(w http.ResponseWriter, r *http.Request) {
|
|||||||
|
|
||||||
log.Debug("rewrite: added element: %s -> %s", rw.Domain, rw.Answer)
|
log.Debug("rewrite: added element: %s -> %s", rw.Domain, rw.Answer)
|
||||||
|
|
||||||
|
d.confLock.Lock()
|
||||||
|
d.Config.Rewrites = d.rewriteStorage.List()
|
||||||
|
d.confLock.Unlock()
|
||||||
|
|
||||||
d.Config.ConfigModified()
|
d.Config.ConfigModified()
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -54,5 +58,9 @@ func (d *DNSFilter) handleRewriteDelete(w http.ResponseWriter, r *http.Request)
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
d.confLock.Lock()
|
||||||
|
d.Config.Rewrites = d.rewriteStorage.List()
|
||||||
|
d.confLock.Unlock()
|
||||||
|
|
||||||
d.Config.ConfigModified()
|
d.Config.ConfigModified()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user