support more type, fixed #3