Updated validation of optional arguments on 'trackevent'