make the logic of parsing name result simple

Change-Id: Idaaa254c6f86924a1de2145db9f241b7414099ac