Return reward to stake balance instead of node's token balance
This commit is contained in:
parent
6d73e1103d
commit
430a994a76
@ -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;
|
||||||
|
Loading…
Reference in New Issue
Block a user