Seems changing to this did the trick (pinched from Theme Customizer) No idea why the first version didn't work.