Skip to content

Commit 86d8429

Browse files
authored
Merge pull request #295 from AugustoL/fix-smart-token
approve before call in approveData in SmartToken
2 parents 08774c9 + 26b92dc commit 86d8429

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

contracts/SmartToken.sol

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,10 @@ contract SmartToken is StandardToken {
3232
function approveData(address _spender, uint256 _value, bytes _data) returns (bool) {
3333
require(_spender != address(this));
3434

35+
super.approve(_spender, _value);
36+
3537
require(_spender.call(_data));
3638

37-
super.approve(_spender, _value);
3839
return true;
3940
}
4041

0 commit comments

Comments
 (0)