diff options
author | 2018-01-07 16:32:59 +0000 | |
---|---|---|
committer | 2018-01-07 16:32:59 +0000 | |
commit | c6febe6250361eee580dbb8a601a444f23ed7ac2 (patch) | |
tree | ee81ab66cfa382d66bc085d31804efb8c1059af2 /plugin/plugin.go | |
parent | 84ebbbc7225a8d7eb5e00c0c525f7e12932a9fe4 (diff) | |
download | coredns-c6febe6250361eee580dbb8a601a444f23ed7ac2.tar.gz coredns-c6febe6250361eee580dbb8a601a444f23ed7ac2.tar.zst coredns-c6febe6250361eee580dbb8a601a444f23ed7ac2.zip |
Add pkg/fall for Fallthrough (#1355)
* Add pkg/fall for Fallthrough
Move this into it's own package to facilitate tests. Important bug
was fixed: make the names fully qualified.
Add fall package to hosts, reverse, etcd, and fix kubernetes and any
tests. The k8s tests are still as-is, might need a future cleanup.
Diffstat (limited to 'plugin/plugin.go')
-rw-r--r-- | plugin/plugin.go | 15 |
1 files changed, 0 insertions, 15 deletions
diff --git a/plugin/plugin.go b/plugin/plugin.go index 137bb48af..a50f10830 100644 --- a/plugin/plugin.go +++ b/plugin/plugin.go @@ -83,21 +83,6 @@ func NextOrFailure(name string, next Handler, ctx context.Context, w dns.Respons return dns.RcodeServerFailure, Error(name, errors.New("no next plugin found")) } -// Fallthrough handles the fallthrough logic used in plugins that support it -func Fallthrough(ftzones *[]string, qname string) bool { - if ftzones == nil { - return false - } - if len(*ftzones) == 0 { - return true - } - zone := Zones(*ftzones).Matches(qname) - if zone != "" { - return true - } - return false -} - // ClientWrite returns true if the response has been written to the client. // Each plugin to adhire to this protocol. func ClientWrite(rcode int) bool { |