TL;DR You shouldn't call $scope.$apply() or $scope.$digest() inside a function that can be invoked by Angular – e.g. in an ngClick.
The linked Stackoverflow answer has a quick overview of techniques to apply changes to a scope. It also explains what might be wrong when you're getting the error $digest already in progress and gives some information that every Angular developer should know.
Posted by Dominik Schöler to makandra dev (2015-03-23 12:32)