Skip to content

Commit

Permalink
Remove watchdogs from existence (#2816)
Browse files Browse the repository at this point in the history
  • Loading branch information
nmarley authored and UdjinM6 committed Mar 30, 2019
1 parent bfc288a commit 74d999e
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 15 deletions.
6 changes: 0 additions & 6 deletions src/governance-object.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -454,10 +454,6 @@ bool CGovernanceObject::IsValidLocally(std::string& strError, bool& fMissingMast
}

switch (nObjectType) {
case GOVERNANCE_OBJECT_WATCHDOG: {
// watchdogs are deprecated
return false;
}
case GOVERNANCE_OBJECT_PROPOSAL: {
CProposalValidator validator(GetDataAsHexString(), true);
// Note: It's ok to have expired proposals
Expand Down Expand Up @@ -519,8 +515,6 @@ CAmount CGovernanceObject::GetMinCollateralFee() const
return GOVERNANCE_PROPOSAL_FEE_TX;
case GOVERNANCE_OBJECT_TRIGGER:
return 0;
case GOVERNANCE_OBJECT_WATCHDOG:
return 0;
default:
return MAX_MONEY;
}
Expand Down
1 change: 0 additions & 1 deletion src/governance-object.h
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ static const double GOVERNANCE_FILTER_FP_RATE = 0.001;
static const int GOVERNANCE_OBJECT_UNKNOWN = 0;
static const int GOVERNANCE_OBJECT_PROPOSAL = 1;
static const int GOVERNANCE_OBJECT_TRIGGER = 2;
static const int GOVERNANCE_OBJECT_WATCHDOG = 3;

static const CAmount GOVERNANCE_PROPOSAL_FEE_TX = (5.0 * COIN);

Expand Down
8 changes: 0 additions & 8 deletions src/rpc/governance.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -184,10 +184,6 @@ UniValue gobject_prepare(const JSONRPCRequest& request)
throw JSONRPCError(RPC_INVALID_PARAMETER, "Trigger objects need not be prepared (however only masternodes can create them)");
}

if (govobj.GetObjectType() == GOVERNANCE_OBJECT_WATCHDOG) {
throw JSONRPCError(RPC_INVALID_PARAMETER, "Watchdogs are deprecated");
}

LOCK2(cs_main, pwallet->cs_wallet);

std::string strError = "";
Expand Down Expand Up @@ -294,10 +290,6 @@ UniValue gobject_submit(const JSONRPCRequest& request)
}
}

if (govobj.GetObjectType() == GOVERNANCE_OBJECT_WATCHDOG) {
throw JSONRPCError(RPC_INVALID_PARAMETER, "Watchdogs are deprecated");
}

// Attempt to sign triggers if we are a MN
if (govobj.GetObjectType() == GOVERNANCE_OBJECT_TRIGGER) {
if (fMnFound) {
Expand Down

0 comments on commit 74d999e

Please sign in to comment.