MCPcopy
hub / github.com/syncthing/syncthing / unwrap

Function unwrap

lib/fs/basicfs_copy_range.go:54–62  ·  view source on GitHub ↗
(f File)

Source from the content-addressed store, hash-verified

52}
53
54func unwrap(f File) File {
55 for {
56 if wrapped, ok := f.(interface{ unwrap() File }); ok {
57 f = wrapped.unwrap()
58 } else {
59 return f
60 }
61 }
62}

Callers 2

TestCopyRangeFunction · 0.85

Calls 1

unwrapMethod · 0.45

Tested by 1

TestCopyRangeFunction · 0.68