smartnode
smartnode copied to clipboard
Make LoadFromFile sane and return an error when load fails.
While trying to use the shared library in a different golang project I found out the hard way that shared/services/config/rocket-pool-config.go's LoadFromFile function (and LoadConfigFromFile) will happily return me a nil pointer when the config file does not exist without returning an error.
This PR makes these functions return an error as I would expect based on the function name (and lacking documentation), and updates the consumers of this function to not break anything.
Tested locally with a blank rocketpool directory, seems to behave as expected.