Return reward to stake balance instead of node's token balance

This commit is contained in:
ChronosX88 2021-07-22 01:02:42 +03:00
parent 6d73e1103d
commit 430a994a76
Signed by: ChronosXYZ
GPG Key ID: 085A69A82C8C511A

View File

@ -85,7 +85,7 @@ contract DioneOracle {
function submitOracleRequest(uint256 _reqID, bytes memory _data) public onlyPendingRequest(_reqID) returns (bool) { function submitOracleRequest(uint256 _reqID, bytes memory _data) public onlyPendingRequest(_reqID) returns (bool) {
require(pendingRequests[_reqID].deadline - int256(block.timestamp) >= 0, "submission has exceeded the deadline"); require(pendingRequests[_reqID].deadline - int256(block.timestamp) >= 0, "submission has exceeded the deadline");
delete pendingRequests[_reqID]; delete pendingRequests[_reqID];
dioneStaking.mine(msg.sender); dioneStaking.mineAndStake(msg.sender);
pendingRequests[_reqID].callbackAddress.call(abi.encodeWithSelector(pendingRequests[_reqID].callbackMethodID, _reqID, _data)); pendingRequests[_reqID].callbackAddress.call(abi.encodeWithSelector(pendingRequests[_reqID].callbackMethodID, _reqID, _data));
emit SubmittedOracleRequest(_reqID, _data); emit SubmittedOracleRequest(_reqID, _data);
return true; return true;