Fixed empty list element appearing sometimes
The takeFirst() function removes the first element in the list... we don't want this to happen!