gitlab.com/evatix-go/core@v1.3.55/coredata/corestr/reflectInterfaceVal.go (about) 1 package corestr 2 3 import "reflect" 4 5 func reflectInterfaceVal(any interface{}) interface{} { 6 rVal := reflect.ValueOf(any) 7 8 if rVal.Kind() != reflect.Ptr { 9 return rVal.Interface() 10 } 11 12 if rVal.Kind() == reflect.Ptr { 13 rVal = rVal.Elem() 14 } 15 16 return rVal.Interface() 17 }