xmpp/xmpp.go
changeset 132 feaa24de9597
parent 131 f9ccfaf672ed
child 134 80b764fa2f08
equal deleted inserted replaced
131:f9ccfaf672ed 132:feaa24de9597
   145 	cl.tlsConfig = tlsconf
   145 	cl.tlsConfig = tlsconf
   146 
   146 
   147 	extStanza := make(map[xml.Name]reflect.Type)
   147 	extStanza := make(map[xml.Name]reflect.Type)
   148 	for _, ext := range exts {
   148 	for _, ext := range exts {
   149 		for k, v := range ext.StanzaHandlers {
   149 		for k, v := range ext.StanzaHandlers {
   150 			if _, ok := extStanza[k]; !ok {
   150 			if _, ok := extStanza[k]; ok {
   151 				return nil, fmt.Errorf("duplicate handler %s",
   151 				return nil, fmt.Errorf("duplicate handler %s",
   152 					k)
   152 					k)
   153 			}
   153 			}
   154 			extStanza[k] = v
   154 			extStanza[k] = v
   155 		}
   155 		}