-
Notifications
You must be signed in to change notification settings - Fork 9
Description
Since schelling is a contract, when transferring COR to it the 'Token._transferToContract(...)' function will be used - it expects the receiving contract to implement the receiveToken function (and it fails in unpredictable ways if that function is not available - see issue 119 ).
It could work only if all of the COR transfers to schelling contract are made using only the Token.transferFromByModule(..) function (since it bypasses _transferToContract(...) ). But this looks kind of fragile and inconsistent.
Also, the schelling.transferEvent(...) function does not handle the case if/when the schelling contract's balance is being decreased, so potentially the rewards variable could become bigger than the balanceOf(schelling) and the newSchellingRound(...) function will fail forever until the contract is replaced.