Fixed bug with menu that made it return the incorrect number of rows if all the rows were not full