MCPcopy Create free account
hub / github.com/bcspragu/logseq-sync / AllFileMeta

Method AllFileMeta

db/mem/mem.go:181–196  ·  view source on GitHub ↗
(_ context.Context, id db.GraphID)

Source from the content-addressed store, hash-verified

179}
180
181func (d *DB) AllFileMeta(_ context.Context, id db.GraphID) ([]*db.FileMeta, error) {
182 g, ok := d.graphs[id]
183 if !ok {
184 return nil, db.NotExists("graph", id)
185 }
186
187 var out []*db.FileMeta
188 for _, metas := range g.metas {
189 if len(metas) == 0 {
190 continue
191 }
192 // Get the latest
193 out = append(out, metas[len(metas)-1])
194 }
195 return out, nil
196}

Callers

nothing calls this directly

Implementers 2

DBdb/mem/mem.go
DBdb/sqlite/sqlite.go

Calls 1

NotExistsFunction · 0.92

Tested by

no test coverage detected