add photo existence check