Remove unnecessary dialog check