fix arity check