From 32046fc1ec63e7d1de61f64d63a246184f04bfc9 Mon Sep 17 00:00:00 2001 From: Alejandro Mery Date: Fri, 8 Sep 2023 13:12:56 +0000 Subject: [PATCH] zones: fix `jpictl dump` by explicitly omitting Machine.logger and Zone.logger if they were fields, as in Zones, they would be ignored automatically. but they aren't Signed-off-by: Alejandro Mery --- pkg/zones/machine.go | 4 ++-- pkg/zones/zones.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/pkg/zones/machine.go b/pkg/zones/machine.go index 2e84f6d..9c9fc7f 100644 --- a/pkg/zones/machine.go +++ b/pkg/zones/machine.go @@ -9,8 +9,8 @@ import ( // A Machine is a machine on a Zone type Machine struct { - zone *Zone - logger + zone *Zone + logger `toml:"-" json:"-" yaml:"-"` ID int `toml:"id"` Name string `toml:"-" json:"-" yaml:"-"` diff --git a/pkg/zones/zones.go b/pkg/zones/zones.go index 3872971..155010c 100644 --- a/pkg/zones/zones.go +++ b/pkg/zones/zones.go @@ -87,8 +87,8 @@ func FilterMachines(m MachineIterator, cond func(*Machine) bool) (Machines, int) // Zone represents one zone in a cluster type Zone struct { - zones *Zones - logger + zones *Zones + logger `toml:"-" json:"-" yaml:"-"` ID int `toml:"id"` Name string `toml:"name"`