WITHDRAW (missing part of function)

Good evening

we have deploy a contract, and when we tryed to withdraw, the transaction worked, but 0 ether was transfered from our smartcontract.

when we have read again our contract, it appear that a large part of the withdrawx function is missing, it is written:

function withdraw() public payable onlyOwner {

and is missing all this:

(bool success, ) = payable(msg.sender).call{value: address(this).balance}("");
require(success);

}
}

please how can we add this to our function / contract and be able to withdraw?

(this misstake has been done because their was a written fuction that was giving 5 % of sale to OpenZeppelin. Their was written that if we do not want to give this, we need to delete this part, but under this was written the real needed fuction, and we deleted it by the same time)

thx

war57

Can you explain more about what do you need? it seems i can't understand your point

So what do you need help with

i need help for upgrade my contract

it is written only one part of the withdraw function so it make it not useable

all contrat is useless without withdraw function

i have this in contract:

function withdraw() public payable onlyOwner {

and is missing all this:

(bool success, ) = payable(msg.sender).call{value: address(this).balance}("");
require(success);

}
}

how to add this part to my contract?