Fixes event listening on back buttons