I am using $ionicViewService.clearHistory() in my application right after I display a page that loads and saves content for my app. This only happens on the installation. When the app is installed, the splash page loads and checks the application for data. If it does not exist, the app is navigated to the login screen. The first thing I do is call $ionicViewService.clearHistory(). The problem is then that my device back button does not exit the application. It just does nothing. Is there any way to resolve this issue? Please let me know if you require any additional information.
It seems the problem arises when I call $ionicViewService.clearHistory() on two screens following one another. If I only call it on one screen there is no problem with the device back button. Any idea what the problem might be?