change function getphoto