continued updating and debugging photo upload scripts