diff --git a/pkg/setup/collection.go b/pkg/setup/collection.go index fcce47d62d6c5a7797e37d19a5b14d440cc0170e..494003d2f7cad1f8977a45913fe1b2ce8bb6c404 100644 --- a/pkg/setup/collection.go +++ b/pkg/setup/collection.go @@ -45,7 +45,10 @@ func NewCollectionConfig(collection *collections.Collection, opt ...CollectionsO func OverwriteCollection() CollectionsOption { return func(c *CollectionConfig) { c.UpdateFn = func(s *Setup, old, new *collections.Collection) (*collections.Collection, bool, bool, error) { - return new, true, true, nil + update := new.Name != old.Name || new.IsSingle() != old.IsSingle() || new.IsSystem() != old.IsSystem() || + new.IsNoData() != old.IsNoData() || new.Hidden != old.Hidden || new.IsView() != old.IsView() || !data.ElementsMatch(old.Tags, new.Tags) + + return new, update, !reflect.DeepEqual(old.Schema, new.Schema), nil } } }