fixed bug when reloading a page and wrong submenu is selected