Remove removes the key and its value from the store in memory Changes are not persisted until you call Save()
(key string)
| 66 | // Remove removes the key and its value from the store in memory |
| 67 | // Changes are not persisted until you call Save() |
| 68 | func (k *Store) Remove(key string) { |
| 69 | k.mu.Lock() |
| 70 | defer k.mu.Unlock() |
| 71 | |
| 72 | delete(k.db, key) |
| 73 | k.logChange(removeOperation, key, nil) |
| 74 | } |
| 75 | |
| 76 | // RemoveAll removes all entries from the store |
| 77 | // These changes are not persisted until you call Save() |