update to button code