Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove watchdogs from existence completely #2816

Merged
merged 1 commit into from
Mar 30, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 0 additions & 6 deletions src/governance-object.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -458,10 +458,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 @@ -523,8 +519,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