fix(): handle failure in hardware back button

This commit is contained in:
mhartington
2018-09-14 10:58:34 -04:00
parent 0c1f8bbc25
commit 6da765b3d5
6 changed files with 25 additions and 12 deletions

View File

@ -21,7 +21,7 @@ export class NavController {
private location: Location,
@Optional() private router?: Router
) {
window && window.document.body.addEventListener('ionBackButton', (ev) => {
window && window.document.addEventListener('ionBackButton', (ev) => {
(ev as BackButtonEvent).detail.register(0, () => this.goBack());
});
}