ing
This commit is contained in:
parent
e216cb7671
commit
e1da1222c6
|
@ -2,6 +2,7 @@ package registry
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
|
"log"
|
||||||
"reflect"
|
"reflect"
|
||||||
"runtime"
|
"runtime"
|
||||||
"strings"
|
"strings"
|
||||||
|
@ -48,7 +49,7 @@ func RegisterType(t reflect.Type) error {
|
||||||
pc, _, _, ok := runtime.Caller(1)
|
pc, _, _, ok := runtime.Caller(1)
|
||||||
details := runtime.FuncForPC(pc)
|
details := runtime.FuncForPC(pc)
|
||||||
if ok && details != nil {
|
if ok && details != nil {
|
||||||
return fmt.Errorf("called from %s", details.Name())
|
log.Printf("called from %s", details.Name())
|
||||||
}
|
}
|
||||||
|
|
||||||
return registry.RegisterType(t)
|
return registry.RegisterType(t)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user