Fixed issue with undefined file name generation and rootNS not working properly.