I'm ok with the ```undefined``` , so I r+ already. Just curious about your thought in this case.
Since this function is unlikely to be called by others, it's not possible to have an unexpected parameter and cause some exception. But if it's a public function in the code base, could we use isNaN to filter out all the invalid parameter, or you prefer to use 2 statements (one for checking the existence and another one for validation) for readability?