fixed bug that dialog can't get message correctly