We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a7e53e0 commit b61e860Copy full SHA for b61e860
cmd/main.go
@@ -22,7 +22,7 @@ func main() {
22
path = envPath
23
}
24
25
- cfg, err := config.NewConfig(path)
+ cfg, err := config.New(path)
26
if err != nil {
27
slog.Error("Config error: " + err.Error())
28
os.Exit(1)
internal/config/config.go
@@ -29,7 +29,7 @@ type (
29
30
)
31
32
-func NewConfig(path string) (*Config, error) {
+func New(path string) (*Config, error) {
33
cfg := &Config{}
34
35
err := cleanenv.ReadConfig(path, cfg)
test/server_integration_test.go
@@ -26,7 +26,7 @@ var (
func TestMain(m *testing.M) {
- cfg, err := config.NewConfig("../configs/config.test.yml")
+ cfg, err := config.New("../configs/config.test.yml")
panic(err)
0 commit comments