function validPurchase() internal constant returns (bool) {
    uint256 current = block.timestamp;
    bool withinPeriod = current >= startTime && current <= endTime;
    bool nonZeroPurchase = msg.value != 0;
    return withinPeriod && nonZeroPurchase;
  }