MCPcopy Create free account
hub / github.com/0xUnixIO/pulse / Upsert

Method Upsert

internal/nodes/memory.go:20–25  ·  view source on GitHub ↗
(node Node)

Source from the content-addressed store, hash-verified

18}
19
20func (s *MemoryStore) Upsert(node Node) (Node, error) {
21 s.mu.Lock()
22 defer s.mu.Unlock()
23 s.nodes[node.ID] = node
24 return node, nil
25}
26
27func (s *MemoryStore) Delete(id string) error {
28 s.mu.Lock()

Calls

no outgoing calls