Added Check for empty image and url