Fixed a bug with checkbox