Skip to content

Commit

Permalink
Merge pull request KomodoPlatform#510 from VerusCoin/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
Asherda authored May 29, 2023
2 parents 6e3c241 + 7e96bd3 commit 3f0f435
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/pbaas/notarization.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -5368,7 +5368,7 @@ bool CPBaaSNotarization::CheckCrossNotarizationProgression(const CCurrencyDefini

// ensure that we can always find one after the first and that we have not moved backwards in the one we find
// any cross confirmed notarization also must have first been confirmed on this chain, so verify that as well
if (foundPriorLocalCrossConfirmed &&
if (foundPriorLocalCrossConfirmed &&
(!foundLocalCrossConfirmed ||
lastConfirmedAddressIndexKey.first.blockHeight < priorLastConfirmedAddressIndexKey.first.blockHeight))
{
Expand Down Expand Up @@ -9303,7 +9303,7 @@ bool PreCheckAcceptedOrEarnedNotarization(const CTransaction &tx, int32_t outNum
bool posNewFormat = (!PBAAS_TESTMODE ||
chainActive[lastConfirmedAddressIndexKey.first.blockHeight]->nTime >= PBAAS_TESTFORK2_TIME);

if (foundPriorLocalCrossConfirmed &&
if (foundPriorLocalCrossConfirmed &&
(!foundLocalCrossConfirmed ||
(posNewFormat &&
lastConfirmedAddressIndexKey.first.blockHeight < priorLastConfirmedAddressIndexKey.first.blockHeight)))
Expand Down Expand Up @@ -10526,6 +10526,7 @@ bool PreCheckFinalizeNotarization(const CTransaction &tx, int32_t outNum, CValid
{
continue;
}
LogPrint("notarization", "%s: notarization finalization tip transaction not in prior chain at height %u\n", __func__, height);
if (confirmNeedsEvidence && (!PBAAS_TESTMODE || chainActive[height - 1]->nTime >= PBAAS_TESTFORK3_TIME))
{
return state.Error("Invalid confirmation evidence 1");
Expand Down
5 changes: 5 additions & 0 deletions src/rpc/pbaasrpc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7097,6 +7097,11 @@ UniValue takeoffer(const UniValue& params, bool fHelp)
throw JSONRPCError(RPC_INVALID_PARAMETER, "identity, " + acceptedIdentity.GetID().GetHex() + ", not found ");
}

if (oldID.HasTokenizedControl())
{
throw JSONRPCError(RPC_INVALID_PARAMETER, "Do not buy an ID with tokenized ID control via the marketplace. Buy the token that is the ID control (or NFT) for a revoked ID with all authorities instead. ID: " + acceptedIdentity.GetID().GetHex());
}

oldID.revocationAuthority = oldID.GetID();
oldID.recoveryAuthority = oldID.GetID();
oldID.privateAddresses.clear();
Expand Down

0 comments on commit 3f0f435

Please sign in to comment.