MCPcopy Create free account
hub / github.com/docker/cli / Erase

Method Erase

cli/config/credentials/native_store.go:33–40  ·  view source on GitHub ↗

Erase removes the given credentials from the native store.

(serverAddress string)

Source from the content-addressed store, hash-verified

31
32// Erase removes the given credentials from the native store.
33func (c *nativeStore) Erase(serverAddress string) error {
34 if err := client.Erase(c.programFunc, serverAddress); err != nil {
35 return err
36 }
37
38 // Fallback to plain text store to remove email
39 return c.fileStore.Erase(serverAddress)
40}
41
42// Get retrieves credentials for a specific server from the native store.
43func (c *nativeStore) Get(serverAddress string) (types.AuthConfig, error) {

Callers 2

TestNativeStoreEraseFunction · 0.95

Calls 1

EraseMethod · 0.65

Tested by 2

TestNativeStoreEraseFunction · 0.76