some fixes with database and menu