added a key check to imageview validation