Skip to content

Commit

Permalink
remove trailing dots from answer
Browse files Browse the repository at this point in the history
  • Loading branch information
dogancanbakir committed Oct 30, 2023
1 parent a4c7647 commit e7eae36
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion pkg/protocols/dns/operators.go
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ func recordsKeyValue(resourceRecords []dns.RR) output.InternalEvent {
var oe = make(output.InternalEvent)
for _, resourceRecord := range resourceRecords {
key := strings.ToLower(dns.TypeToString[resourceRecord.Header().Rrtype])
value := strings.ReplaceAll(resourceRecord.String(), resourceRecord.Header().String(), "")
value := strings.TrimSuffix(strings.ReplaceAll(resourceRecord.String(), resourceRecord.Header().String(), ""), ".")

// if the key is already present, we need to convert the value to a slice
// if the key has slice, then append the value to the slice
Expand Down

0 comments on commit e7eae36

Please sign in to comment.