contract DegenLocker is Context, Ownable {
    
    uint256 public lockperiod;
    bool public lplocked;

    constructor() {
    }
   

    function getLockTimeRemaining() public view returns (uint256) {
        return lockperiod - block.timestamp;
    }

    function LockLPtokens(uint256 time) public onlyOwner() {
        require(lplocked != true, "lock: error");
        lockperiod = block.timestamp + time;  
        lplocked = true;
    }
    
    function ExtendLPlockPeriod(uint256 time) public onlyOwner() {
         require(lplocked = true, "lock: error");
         require(time > 0, "lock: error");
         lockperiod += time;
    }

    function withdrawLPtokens(IERC20 lpaddress) public onlyOwner() {
       require(block.timestamp >= lockperiod, "LP is still locked ser");
       lpaddress.transfer(_msgSender(), lpaddress.balanceOf(address(this)));
       lplocked = false;
    }

    // to rescue ETH sent by accident
    function  clearStuckBalance() public onlyOwner() {
        payable(_msgSender()).transfer(address(this).balance);
    }
    
    receive() external payable {}

}
function  clearStuckBalance() public onlyOwner() {
    payable(_msgSender()).transfer(address(this).balance);
}

// to rescue ETH sent by accident