added emptySlot function