@@ -47,17 +47,17 @@ contract IexecAPI is OwnableOZ, IexecHubAccessor, IexecCallbackInterface
4747 return true ;
4848 }
4949
50- function approveIexecHub (uint256 amount ) public onlyOwner returns (bool )
50+ function approveIexecHub (uint256 amount , address rlcAddress ) public onlyOwner returns (bool )
5151 {
52- RLC rlc = RLC (iexecHubInterface. getRLCAddress () );
52+ RLC rlc = RLC (rlcAddress );
5353 require (rlc.approve (iexecHubAddress, amount));
5454 emit ApproveIexecHub (iexecHubAddress, amount);
5555 return true ;
5656 }
5757
58- function withdrawRLCFromIexecAPI (uint256 amount ) public onlyOwner returns (bool )
58+ function withdrawRLCFromIexecAPI (uint256 amount , address rlcAddress ) public onlyOwner returns (bool )
5959 {
60- RLC rlc = RLC (iexecHubInterface. getRLCAddress () );
60+ RLC rlc = RLC (rlcAddress );
6161 require (rlc.transfer (msg .sender , amount));
6262 emit WithdrawRLCFromIexecAPI (msg .sender , amount);
6363 return true ;
@@ -70,10 +70,10 @@ contract IexecAPI is OwnableOZ, IexecHubAccessor, IexecCallbackInterface
7070 return true ;
7171 }
7272
73- function withdrawRLCFromIexecHub (uint256 amount ) public onlyOwner returns (bool )
73+ function withdrawRLCFromIexecHub (uint256 amount , address rlcAddress ) public onlyOwner returns (bool )
7474 {
7575 require (iexecHubInterface.withdraw (amount));
76- require (withdrawRLCFromIexecAPI (amount));
76+ require (withdrawRLCFromIexecAPI (amount,rlcAddress ));
7777 emit WithdrawRLCFromIexecHub (iexecHubAddress, amount);
7878 return true ;
7979 }
0 commit comments