remove creating empty default config

This commit is contained in:
Maxim Merzhanov authored and Maxim committed 2019-10-30 11:06:03 +03:00
1 parent 1fe8b7f78d
commit 415a694228
1 file changed
+1 -1
+1 -1
View File
@@ -108,7 +108,7 @@ func (h *socketEventHandler) handleConfigSchema(conn etp.Conn, data []byte) []by
h.store.VisitReadonlyState(func(readState state.ReadonlyState) {
configs = readState.Configs().GetByModuleIds([]string{module.Id})
})
if len(configs) == 0 {
if len(configs) == 0 && len(configSchema.DefaultConfig) > 0 {
config := entity.Config{
Id: state.GenerateId(),
Name: module.Name,