cleanup & fixed back button