@@ -49,17 +49,6 @@ contract Passage {
49
49
emit Enter (rollupChainId, address (0 ), rollupRecipient, msg .value );
50
50
}
51
51
52
- /// @notice Allows ERC20s to enter the rollup.
53
- /// @param rollupChainId - The rollup chain to enter.
54
- /// @param rollupRecipient - The recipient of the Ether on the rollup.
55
- /// @param token - The address of the ERC20 token on the Host.
56
- /// @param amount - The amount of the ERC20 token to transfer to the rollup.
57
- /// @custom:emits Enter indicating the amount of tokens to mint on the rollup & its recipient.
58
- function enter (uint256 rollupChainId , address token , address rollupRecipient , uint256 amount ) external payable {
59
- IERC20 (token).transferFrom (msg .sender , address (this ), amount);
60
- emit Enter (rollupChainId, token, rollupRecipient, amount);
61
- }
62
-
63
52
/// @notice Allows the admin to withdraw ETH or ERC20 tokens from the contract.
64
53
/// @dev Only the admin can call this function.
65
54
function withdraw (address token , address recipient , uint256 amount ) external {
@@ -96,34 +85,11 @@ contract RollupPassage {
96
85
hostPassage = _hostPassage;
97
86
}
98
87
99
- /// @notice Allows ERC20s to enter the rollup from L1.
100
- /// @param token - The address of the L1 ERC20 token to mint a representation for.
101
- /// @param rollupRecipient - The recipient of the ERC20 tokens on the rollup, specified by the sender on L1.
102
- /// @param amount - The amount of the ERC20 token to mint on the Rollup, corresponding to the amount locked on L1.
103
- /// @custom:emits Exit indicating the the desired recipient on the host chain.
104
- function enter (address token , address rollupRecipient , uint256 amount ) external {
105
- // TODO: important that no code is deployed to hostPassage address on the rollup :think:
106
- if (msg .sender != hostPassage) revert OnlyHostPassage ();
107
- // TODO: IERC20(token).mint(recipient, amount);
108
- emit Enter (token, rollupRecipient, amount);
109
- }
110
-
111
88
/// @notice Allows native Ether to exit the rollup.
112
89
/// @dev Rollup node will burn the msg.value.
113
90
/// @param recipient - The desired recipient of the Ether on the host chain.
114
91
/// @custom:emits Exit indicating the amount of Ether to burn on the rollup & the recipient on the host chain.
115
92
function exit (address recipient ) public payable {
116
93
emit Exit (address (0 ), recipient, msg .value );
117
94
}
118
-
119
- /// @notice Allows ERC20s to exit the rollup.
120
- /// @param recipient - The desired recipient of the ERC20s on the host chain.
121
- /// @param token - The address of the ERC20 token on the Rollup.
122
- /// @param amount - The amount of the ERC20 token to burn on the Rollup.
123
- /// @custom:emits Exit indicating the the desired recipient on the host chain.
124
- function exit (address token , address recipient , uint256 amount ) external payable {
125
- IERC20 (token).transferFrom (msg .sender , address (this ), amount);
126
- // TODO: IERC20(token).burn(msg.sender, amount);
127
- emit Exit (token, recipient, amount);
128
- }
129
95
}
0 commit comments