check the unionid first.