Nonlocal compensation of pure phase objects with entangled photons