MCPcopy Create free account
hub / github.com/blues/note / GetNote

Method GetNote

lib/notebox.go:1369–1380  ·  view source on GitHub ↗

GetNote gets a note from a notefile

(ctx context.Context, notefileID string, noteID string)

Source from the content-addressed store, hash-verified

1367
1368// GetNote gets a note from a notefile
1369func (box *Notebox) GetNote(ctx context.Context, notefileID string, noteID string) (note note.Note, err error) {
1370 openfile, file, err := box.OpenNotefile(ctx, notefileID)
1371 if err != nil {
1372 return
1373 }
1374
1375 note, err = file.GetNote(noteID)
1376
1377 openfile.Close(ctx)
1378
1379 return
1380}
1381
1382// Checks a notefile and rejects attempts to add more than 100 notes
1383func (box *Notebox) checkAddNoteLimits(ctx context.Context, notefileID string, noteObj note.Note) (err error) {

Callers 6

RequestMethod · 0.95
GetNotefileInfoMethod · 0.45
SetNotefileInfoMethod · 0.45
hubWebRequestFunction · 0.45
hubSignalFunction · 0.45
hubNotefileUpdateNoteFunction · 0.45

Calls 2

OpenNotefileMethod · 0.95
CloseMethod · 0.45

Tested by

no test coverage detected