CORIONplatform / solidity

GNU General Public License v3.0
12 stars 9 forks source link

checkReward(...) function declared constant #149

Closed gundas closed 7 years ago

gundas commented 7 years ago

https://github.com/CORIONplatform/solidity/blob/provider-recode/provider.sol#L1431

the current implementation of checkReward(...) function does modify state (is not idempotent).

iFA88 commented 7 years ago

Yes, because we want only to check the rewards. What is the problem with that?

gundas commented 7 years ago

I am not sure if it is a problem - a constant function is a promise not to modify any state. Works in Remix.

iFA88 commented 7 years ago

Sorry, I still don't understand what is the problem. The checkReward should not do any change on the blockchain, this is why that are constant.