beast icon indicating copy to clipboard operation
beast copied to clipboard

Wrap BeastConfig and Config struct initialization to a New function

Open fristonio opened this issue 5 years ago • 0 comments

Currently, the structs objects are initialized manually by providing values to the struct fields directly. This leaves us with a situation where we have to rely on the Validate method for default values to be populated. Wrap all such places with a function in config like NewBeastConfig and NewChallengeConfig and decode the values from the toml so that default values can be sensibly initialized. View the issue to look at how we can deal with this https://github.com/BurntSushi/toml/issues/47

fristonio avatar Oct 19 '19 13:10 fristonio