revert back to use state for checkbox