1
0
Fork 0
mirror of https://github.com/anyproto/any-sync.git synced 2025-06-10 18:10:54 +09:00

Update compatibility with old protocol - requests

This commit is contained in:
mcrakhman 2024-07-31 00:51:40 +02:00
parent 611390987c
commit cf4c19b37d
No known key found for this signature in database
GPG key ID: DED12CFEF5B8396B

View file

@ -115,8 +115,12 @@ func (o *objectSync) HandleDeprecatedObjectSync(ctx context.Context, req *spaces
if err != nil {
return nil, err
}
cnt.Changes = nil
marshalled, err := proto.Marshal(unmarshalled)
resp := &treechangeproto.TreeFullSyncResponse{
Heads: cnt.Heads,
SnapshotPath: cnt.SnapshotPath,
}
syncMsg := treechangeproto.WrapFullResponse(resp, unmarshalled.RootChange)
marshalled, err := proto.Marshal(syncMsg)
if err != nil {
return nil, err
}