function () external payable {                                            
    require(openingTime <= block.timestamp && block.timestamp <= closingTime);      
    require(whitelist[msg.sender]);        
    require(msg.value >= threshold );      
    require(weiRaised.add(msg.value) <= hardCap );      
    buyTokens(msg.sender);
  }