You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
12 lines
216 B
12 lines
216 B
2 months ago
|
package safeMap
|
||
|
|
||
|
func (m *SafeMap) Clean() {
|
||
|
keys := make([]string, 0, m.Map.Count())
|
||
|
m.Iter(func(key string, v interface{}) {
|
||
|
keys = append(keys, key)
|
||
|
})
|
||
|
for _, key := range keys {
|
||
|
m.Set(key, int64(0))
|
||
|
}
|
||
|
}
|