Cleaned addPhoto Code