Updated type_convert to make more sense and not need special cases.