Skip to content

Commit

Permalink
Make all the fork/filter heights pointers so that they serialize to y… (
Browse files Browse the repository at this point in the history
  • Loading branch information
cmmarslender authored Sep 25, 2024
1 parent b106592 commit 12cc9fc
Showing 1 changed file with 7 additions and 6 deletions.
13 changes: 7 additions & 6 deletions pkg/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,13 @@ type NetworkConstants struct {
MinPlotSize uint8 `yaml:"MIN_PLOT_SIZE,omitempty" json:"MIN_PLOT_SIZE,omitempty"`
NetworkType uint8 `yaml:"NETWORK_TYPE,omitempty" json:"NETWORK_TYPE,omitempty"`
SubSlotItersStarting uint64 `yaml:"SUB_SLOT_ITERS_STARTING,omitempty" json:"SUB_SLOT_ITERS_STARTING,omitempty"`
HardForkHeight uint32 `yaml:"HARD_FORK_HEIGHT,omitempty" json:"HARD_FORK_HEIGHT,omitempty"`
SoftFork4Height uint32 `yaml:"SOFT_FORK4_HEIGHT,omitempty" json:"SOFT_FORK4_HEIGHT,omitempty"`
SoftFork5Height uint32 `yaml:"SOFT_FORK5_HEIGHT,omitempty" json:"SOFT_FORK5_HEIGHT,omitempty"`
PlotFilter128Height uint32 `yaml:"PLOT_FILTER_128_HEIGHT,omitempty" json:"PLOT_FILTER_128_HEIGHT,omitempty"`
PlotFilter64Height uint32 `yaml:"PLOT_FILTER_64_HEIGHT,omitempty" json:"PLOT_FILTER_64_HEIGHT,omitempty"`
PlotFilter32Height uint32 `yaml:"PLOT_FILTER_32_HEIGHT,omitempty" json:"PLOT_FILTER_32_HEIGHT,omitempty"`
// All pointers that that 0 is an allowed value when marshaling with omitempty, but they will still be omitted from configs that dont have them defined
HardForkHeight *uint32 `yaml:"HARD_FORK_HEIGHT,omitempty" json:"HARD_FORK_HEIGHT,omitempty"`
SoftFork4Height *uint32 `yaml:"SOFT_FORK4_HEIGHT,omitempty" json:"SOFT_FORK4_HEIGHT,omitempty"`
SoftFork5Height *uint32 `yaml:"SOFT_FORK5_HEIGHT,omitempty" json:"SOFT_FORK5_HEIGHT,omitempty"`
PlotFilter128Height *uint32 `yaml:"PLOT_FILTER_128_HEIGHT,omitempty" json:"PLOT_FILTER_128_HEIGHT,omitempty"`
PlotFilter64Height *uint32 `yaml:"PLOT_FILTER_64_HEIGHT,omitempty" json:"PLOT_FILTER_64_HEIGHT,omitempty"`
PlotFilter32Height *uint32 `yaml:"PLOT_FILTER_32_HEIGHT,omitempty" json:"PLOT_FILTER_32_HEIGHT,omitempty"`
}

// NetworkConfig specific network configuration settings
Expand Down

0 comments on commit 12cc9fc

Please sign in to comment.