diff --git a/filemgr/config_manager.go b/filemgr/config_manager.go index 68dbc04..431e27d 100644 --- a/filemgr/config_manager.go +++ b/filemgr/config_manager.go @@ -91,6 +91,10 @@ func (fsr *FsRepo) checkConfig(op *OverrideParams) error { cnf.APIRegisterHub.SupportAccounts = op.SupportAccounts } } + if cnf.SignFilter == nil { + cnf.SignFilter = &config.SignFilter{} + } + if reset { err = config.CoverConfig(fsr.configPath(), cnf) if err != nil { diff --git a/filemgr/fs_test.go b/filemgr/fs_test.go index 9081007..613209d 100644 --- a/filemgr/fs_test.go +++ b/filemgr/fs_test.go @@ -39,4 +39,8 @@ func TestNewFS(t *testing.T) { t.Fatal() } assert.Equal(t, curAPI, targetAPI) + + require.NotNil(t, fs.Config().Factor) + require.NotNil(t, fs.Config().SignFilter) + require.NotNil(t, fs.Config().APIRegisterHub) }