fix issues with name being nil