11 lines
180 B
Go
11 lines
180 B
Go
|
package gobstore
|
||
|
|
||
|
// Delete removes a key if it exists
|
||
|
func (j *GobStore[T]) Delete(key string) {
|
||
|
j.Lock()
|
||
|
defer j.Unlock()
|
||
|
j.dirty = true
|
||
|
delete(j.values, key)
|
||
|
// j.save()
|
||
|
}
|