Fix on function type check