Fixed name parsing not working in some cases