diff --git a/prepare.go b/prepare.go index e52090b..791547f 100644 --- a/prepare.go +++ b/prepare.go @@ -1443,13 +1443,12 @@ func prepareAT(text string) string { func prepareSK(text string) string { tokens := map[string]string{ - "Domain registrant": "Registrant", - "Authorised Registrar": "Registrar", + "Domain registrant": "Registrant", + "Authorised Registrar": "Registrar", "Administrative Contact": "Administrative", "Technical Contact": "Technical", } - token := "" result := "" prefix := "" @@ -1459,14 +1458,13 @@ func prepareSK(text string) string { v = strings.Replace(v, "\r", "", -1) if v == "" { - token = "" continue } - if strings.Contains(v,":"){ + if strings.Contains(v, ":") { vs := strings.SplitN(v, ":", 2) value := strings.TrimSpace(vs[1]) - token = strings.TrimSpace(vs[0]) + token := strings.TrimSpace(vs[0]) if _, ok := tokens[token]; ok { prefix = tokens[token] @@ -1481,4 +1479,3 @@ func prepareSK(text string) string { return result } - diff --git a/rule.go b/rule.go index 257b027..9194aca 100644 --- a/rule.go +++ b/rule.go @@ -73,7 +73,7 @@ var ( "domain registered": "created_date", "modified": "updated_date", "changed": "updated_date", - "updated": "updated_date", + "updated": "updated_date", "update date": "updated_date", "updated date": "updated_date", "updated on": "updated_date", @@ -119,7 +119,7 @@ var ( "registrant nic hdl": "registrant_id", "registrant nic handle": "registrant_id", "registrant org id": "registrant_id", - "registrant domain registrant": "registrant_id", + "registrant domain registrant": "registrant_id", "registrant name": "registrant_name", "registrant person": "registrant_name", "registrant contact": "registrant_name",