Fixed a bug with menu
Removed unnecessary functions