File tree Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Expand file tree Collapse file tree 1 file changed +9
-2
lines changed Original file line number Diff line number Diff line change @@ -75,9 +75,16 @@ contract StylusDeployer {
75
75
// initialize - this will fail if the program wasn't activated by this point
76
76
// we check if initData exists to avoid calling contracts unnecessarily
77
77
if (initData.length != 0 ) {
78
- (bool success ,) = address (newContractAddress).call {value: initValue}(initData);
78
+ (bool success , bytes32 memory data ) =
79
+ address (newContractAddress).call {value: initValue}(initData);
79
80
if (! success) {
80
- revert ContractInitializationError (newContractAddress);
81
+ if (data.length > 0 ) {
82
+ assembly {
83
+ revert (add (data, 32 ), mload (data))
84
+ }
85
+ } else {
86
+ revert ContractInitializationError (newContractAddress);
87
+ }
81
88
}
82
89
} else if (initValue != 0 ) {
83
90
// if initValue exists init data should too
You can’t perform that action at this time.
0 commit comments