fix undefined params