Rolling back some changes to try and get this working.