Fixed #29. Remember to run $scope.initCheckboxes after all checkboxes has been populated.