Fix bad check for argument length

it was causing a notice