MCPcopy Create free account
hub / github.com/evilsocket/ditto / fixArrays

Function fixArrays

cmd/ditto/changes.go:101–114  ·  view source on GitHub ↗
(d *whoisparser.Domain)

Source from the content-addressed store, hash-verified

99}
100
101func fixArrays(d *whoisparser.Domain) {
102 if len(d.Status) == 0 && d.Status != nil {
103 d.Status = nil
104 }
105 if d.Status != nil {
106 sort.Strings(d.Status)
107 }
108 if len(d.NameServers) == 0 && d.NameServers != nil {
109 d.NameServers = nil
110 }
111 if d.NameServers != nil {
112 sort.Strings(d.NameServers)
113 }
114}
115
116func whoisCompare(a, b *whoisparser.WhoisInfo) (bool, string) {
117 if a == nil && b != nil {

Callers 1

whoisCompareFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected