Skip to content

Commit a05e964

Browse files
authored
Update Create2.sol
1 parent 2a4cc06 commit a05e964

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

contracts/utils/Create2.sol

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,8 +46,11 @@ library Create2 {
4646
addr := create2(amount, add(bytecode, 0x20), mload(bytecode), salt)
4747
}
4848
if (addr == address(0)) {
49-
if (LowLevelCall.returnDataSize() != 0) LowLevelCall.bubbleRevert(LowLevelCall.returnData());
50-
else revert Errors.FailedDeployment();
49+
if (LowLevelCall.returnDataSize() == 0) {
50+
revert Errors.FailedDeployment();
51+
} else {
52+
LowLevelCall.bubbleRevert();
53+
}
5154
}
5255
}
5356

0 commit comments

Comments
 (0)