Correct the number of buttons