Update button code to be shorter