fix bug that caused checkboxes not to work