ing
This commit is contained in:
parent
b221ead4e4
commit
ea2b6398a7
|
@ -16,8 +16,9 @@ type AttributeManagers struct {
|
|||
|
||||
func (am *AttributeManagers) Init() {
|
||||
if nil == am.attributes {
|
||||
am.attributes = make(map[string]interface{})
|
||||
am.Destroy()
|
||||
}
|
||||
am.attributes = make(map[string]interface{})
|
||||
}
|
||||
|
||||
func (am *AttributeManagers) SetAttribute(key string, value interface{}) {
|
||||
|
@ -62,7 +63,7 @@ func (am *AttributeManagers) Contains(key string) (exist bool) {
|
|||
}
|
||||
|
||||
func (am *AttributeManagers) Destroy() {
|
||||
if nil == am.attributes {
|
||||
if nil != am.attributes {
|
||||
am.attributes = nil
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user