fix for checkbox bug