Influence of oxygen on structural transitions in Pr2NiO4+δ