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

Method DeleteWithContext

middleware/csrf/csrf_test.go:2617–2625  ·  view source on GitHub ↗
(_ context.Context, key string)

Source from the content-addressed store, hash-verified

2615}
2616
2617func (s *flakySessionStorage) DeleteWithContext(_ context.Context, key string) error {
2618 s.mu.Lock()
2619 defer s.mu.Unlock()
2620 if s.failDel {
2621 return errors.New("delete failed")
2622 }
2623 delete(s.data, key)
2624 return nil
2625}
2626
2627func (s *flakySessionStorage) Delete(key string) error {
2628 return s.DeleteWithContext(context.Background(), key)

Callers 1

DeleteMethod · 0.95

Calls 3

LockMethod · 0.65
UnlockMethod · 0.65
NewMethod · 0.65

Tested by

no test coverage detected