summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShulhan <ms@kilabit.info>2022-05-16 15:56:38 +0700
committerShulhan <ms@kilabit.info>2022-05-16 15:56:38 +0700
commita44f87fbd19b1f9e2d99fbf1aefb91f13ebff6e3 (patch)
treebf283fc78acbdb8262780dbb45cf66a1a04bc1d5
parent3f8e9c633334851626a94df36517ee29bf2d8c90 (diff)
downloadpakakeh.go-a44f87fbd19b1f9e2d99fbf1aefb91f13ebff6e3.tar.xz
lib/dns: disable JSON marshaling Zone Records field
On service that manage many zones, providing an API to fetch list of zones only will return large payload if we include the Records field in the response. So, it is recommended to provide another API to fetch the records on specific zone.
-rw-r--r--lib/dns/zone.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/dns/zone.go b/lib/dns/zone.go
index f99175cd..e1e2a3f4 100644
--- a/lib/dns/zone.go
+++ b/lib/dns/zone.go
@@ -18,8 +18,8 @@ import (
// Zone represent a group of domain names shared a single root domain.
// A Zone contains at least one SOA record.
type Zone struct {
- Records ZoneRecords
- Path string `json:"-"`
+ Records ZoneRecords `json:"-"`
+ Path string `json:"-"`
Name string
messages []*Message
SOA RDataSOA