From 6ea154a54a7c20bab1a617f1338451d5ddf04a15 Mon Sep 17 00:00:00 2001 From: Andrew Falaleev Date: Wed, 14 Aug 2019 20:24:20 +0700 Subject: [PATCH] Fix unvote. --- golos.publication/golos.publication.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/golos.publication/golos.publication.cpp b/golos.publication/golos.publication.cpp index 1f7c1587..9d9850e6 100644 --- a/golos.publication/golos.publication.cpp +++ b/golos.publication/golos.publication.cpp @@ -774,7 +774,7 @@ fixp_t publication::calc_available_rshares(name voter, int16_t weight, uint64_t auto used_power = use_charge(lims, structures::limitparams::VOTE, token::get_issuer(config::token_name, token_code), voter, eff_vesting, token_code, false, weight); fixp_t abs_rshares = FP(eff_vesting) * elaf_t(elai_t(used_power) / elai_t(config::_100percent)); - eosio::check(abs_rshares >= FP(params().min_abs_rshares_param.value), "too low vote weight"); + eosio::check(!weight || abs_rshares >= FP(params().min_abs_rshares_param.value), "too low vote weight"); return (weight < 0) ? -abs_rshares : abs_rshares; }