package synchronizator import "reflect" func getTypeOfStruct(shape interface{}) string { // Get the type and handle pointer types t := reflect.TypeOf(shape) if t.Kind() == reflect.Ptr { t = t.Elem() } return t.Name() }