Fixed back button crash in search
Split up menu logic