fix id compare for view or edit message