MCPcopy
hub / github.com/syncthing/syncthing / IndexUpdate

Method IndexUpdate

lib/protocol/encryption.go:71–79  ·  view source on GitHub ↗
(idxUp *IndexUpdate)

Source from the content-addressed store, hash-verified

69}
70
71func (e encryptedModel) IndexUpdate(idxUp *IndexUpdate) error {
72 if folderKey, ok := e.folderKeys.get(idxUp.Folder); ok {
73 // incoming index data to be decrypted
74 if err := decryptFileInfos(e.keyGen, idxUp.Files, folderKey); err != nil {
75 return err
76 }
77 }
78 return e.model.IndexUpdate(idxUp)
79}
80
81func (e encryptedModel) Request(req *Request) (RequestResponse, error) {
82 folderKey, ok := e.folderKeys.get(req.Folder)

Callers

nothing calls this directly

Calls 3

decryptFileInfosFunction · 0.85
getMethod · 0.65
IndexUpdateMethod · 0.65

Tested by

no test coverage detected