MCPcopy
hub / github.com/gofiber/fiber / DeleteWithContext

Method DeleteWithContext

shared_state.go:220–231  ·  view source on GitHub ↗
(ctx context.Context, key string)

Source from the content-addressed store, hash-verified

218}
219
220func (s *SharedState) DeleteWithContext(ctx context.Context, key string) error {
221 if err := s.ensureStorage(); err != nil {
222 return err
223 }
224
225 storageKey, ok := s.storageKey(key)
226 if !ok {
227 return nil
228 }
229
230 return s.storage.DeleteWithContext(ctx, storageKey)
231}
232
233func (s *SharedState) Has(key string) (bool, error) {
234 return s.HasWithContext(context.Background(), key)

Callers 1

DeleteMethod · 0.95

Calls 3

ensureStorageMethod · 0.95
storageKeyMethod · 0.95
DeleteWithContextMethod · 0.65

Tested by

no test coverage detected