From 318a49c526efeaad5267d6105f6e16c24a3d24bb Mon Sep 17 00:00:00 2001 From: mcrakhman Date: Wed, 7 Jun 2023 22:05:05 +0200 Subject: [PATCH] Change objectsync injection --- commonspace/objectsync/objectsync.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/commonspace/objectsync/objectsync.go b/commonspace/objectsync/objectsync.go index d2febaee..0ec7f344 100644 --- a/commonspace/objectsync/objectsync.go +++ b/commonspace/objectsync/objectsync.go @@ -6,6 +6,7 @@ import ( "fmt" "github.com/anyproto/any-sync/app" "github.com/anyproto/any-sync/commonspace/object/tree/treechangeproto" + "github.com/anyproto/any-sync/commonspace/object/treemanager" "github.com/anyproto/any-sync/commonspace/spacestate" "github.com/anyproto/any-sync/metric" "github.com/anyproto/any-sync/net/peer" @@ -69,7 +70,7 @@ type objectSync struct { func (s *objectSync) Init(a *app.App) (err error) { s.spaceStorage = a.MustComponent(spacestorage.CName).(spacestorage.SpaceStorage) - s.objectGetter = app.MustComponent[syncobjectgetter.SyncObjectGetter](a) + s.objectGetter = a.MustComponent(treemanager.CName).(syncobjectgetter.SyncObjectGetter) s.configuration = a.MustComponent(nodeconf.CName).(nodeconf.NodeConf) sharedData := a.MustComponent(spacestate.CName).(*spacestate.SpaceState) mc := a.Component(metric.CName)