From 1d127c8ab21ad50e35aea2cea87008b1a47a3df1 Mon Sep 17 00:00:00 2001 From: "A.Unger" Date: Wed, 17 Nov 2021 16:43:02 +0100 Subject: [PATCH] remove dead code from store regarding common propagation --- store/pkg/command/server.go | 25 +------------------------ 1 file changed, 1 insertion(+), 24 deletions(-) diff --git a/store/pkg/command/server.go b/store/pkg/command/server.go index 622719874..a8677eb16 100644 --- a/store/pkg/command/server.go +++ b/store/pkg/command/server.go @@ -3,10 +3,6 @@ package command import ( "context" - gofig "github.com/gookit/config/v2" - ociscfg "github.com/owncloud/ocis/ocis-pkg/config" - "github.com/owncloud/ocis/ocis-pkg/shared" - "github.com/owncloud/ocis/store/pkg/tracing" "github.com/owncloud/ocis/ocis-pkg/sync" @@ -25,26 +21,7 @@ func Server(cfg *config.Config) *cli.Command { Name: "server", Usage: "Start integrated server", Before: func(ctx *cli.Context) error { - // remember shared logging info to prevent empty overwrites - inLog := cfg.Log - if err := ParseConfig(ctx, cfg); err != nil { - return err - } - - if (cfg.Log == shared.Log{}) && (inLog != shared.Log{}) { - // set the default to the parent config - cfg.Log = inLog - - // and parse the environment - conf := &gofig.Config{} - conf.LoadOSEnv(config.GetEnv(), false) - bindings := config.StructMappings(cfg) - if err := ociscfg.BindEnv(conf, bindings); err != nil { - return err - } - } - - return nil + return ParseConfig(ctx, cfg) }, Action: func(c *cli.Context) error { logger := NewLogger(cfg)