updatePrettySwitch function

Change the value of a pretty switch on the client