added isValidSlot and isInteger