[fix] Better type checking and type normalization