Skip to content

Commit

Permalink
Merge pull request #122 from Bananapus/fix/DeployERC20ForReentrency
Browse files Browse the repository at this point in the history
fix: resolved an theoretical low impact reentrency although was not a vulnerability in its current state
  • Loading branch information
xBA5ED authored Apr 1, 2024
2 parents d4c90ae + 263c813 commit ef4f60d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/JBTokens.sol
Original file line number Diff line number Diff line change
Expand Up @@ -145,15 +145,15 @@ contract JBTokens is JBControlled, IJBTokens {
? IJBToken(Clones.clone(address(TOKEN)))
: IJBToken(Clones.cloneDeterministic(address(TOKEN), keccak256(abi.encode(msg.sender, salt))));

// Initialize the token.
token.initialize({name: name, symbol: symbol, owner: address(this)});

// Store the token contract.
tokenOf[projectId] = token;

// Store the project for the token.
projectIdOf[token] = projectId;

// Initialize the token.
token.initialize({name: name, symbol: symbol, owner: address(this)});

emit DeployERC20(projectId, token, name, symbol, salt, msg.sender);
}

Expand Down

0 comments on commit ef4f60d

Please sign in to comment.