added a fix for back-button navigation