Manager: always set config.currentGOOS

This variable is used in tests to mock the current OS, but wasn't set
during normal operation of the Manager. This caused issues with the
two-way variable system.
This commit is contained in:
Sybren A. Stüvel 2022-08-31 11:43:28 +02:00
parent 0a1e1efc41
commit 31769bcdf2

View File

@ -174,6 +174,7 @@ func DefaultConfig(override ...func(c *Conf)) Conf {
panic(fmt.Sprintf("unable to create copy of default config: %v", err))
}
c.Meta.Version = latestConfigVersion
c.currentGOOS = VariablePlatform(runtime.GOOS)
c.processAfterLoading(override...)
return *c
}