fix routing when closing settings