$ionicPlatform Current View/Controller Detection

Solved it by using:

$scope.$on('$destroy', function(event) {
 // function
});

Referencing this thread for people who might encounter the same problem.

Thanks.

1 Like