apply geoffs patch
moving stuff around