Skip to content

Commit 499003c

Browse files
committed
remove unused parameters
1 parent 6f65ee3 commit 499003c

File tree

23 files changed

+32
-62
lines changed

23 files changed

+32
-62
lines changed

src/Ethernaut/CoinFlip/CoinFlipFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ import "../Ethernaut/Level.sol";
66
import "./CoinFlip.sol";
77

88
contract CoinFlipFactory is Level {
9-
function createInstance(address _player) public payable override returns (address) {
10-
_player;
9+
function createInstance(address /* _player */) public payable override returns (address) {
1110
return address(new CoinFlip());
1211
}
1312

src/Ethernaut/Delegation/DelegationFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@ contract DelegationFactory is Level {
1313
delegateAddress = address(newDelegate);
1414
}
1515

16-
function createInstance(address _player) public payable override returns (address) {
17-
_player;
16+
function createInstance(address /* _player */) public payable override returns (address) {
1817
Delegation parity = new Delegation(delegateAddress);
1918
return address(parity);
2019
}

src/Ethernaut/Denial/DenialFactory.sol

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,15 @@ import "./Denial.sol";
88
contract DenialFactory is Level {
99
uint256 public initialDeposit = 0.001 ether;
1010

11-
function createInstance(address _player) public payable override returns (address) {
12-
_player;
11+
function createInstance(address /* _player */) public payable override returns (address) {
1312
require(msg.value >= initialDeposit);
1413
Denial instance = new Denial();
1514
(bool result,) = address(instance).call{value: msg.value}("");
1615
require(result);
1716
return address(instance);
1817
}
1918

20-
function validateInstance(address payable _instance, address _player) public override returns (bool) {
21-
_player;
19+
function validateInstance(address payable _instance, address /* _player */) public override returns (bool) {
2220
Denial instance = Denial(_instance);
2321
if (address(instance).balance <= 100 wei) {
2422
// cheating otherwise

src/Ethernaut/Elevator/ElevatorFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ import "../Ethernaut/Level.sol";
66
import "./Elevator.sol";
77

88
contract ElevatorFactory is Level {
9-
function createInstance(address _player) public payable override returns (address) {
10-
_player;
9+
function createInstance(address /* _player */) public payable override returns (address) {
1110
Elevator instance = new Elevator();
1211
return address(instance);
1312
}

src/Ethernaut/Fallback/FallbackFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ import "./Fallback.sol";
55
import "../Ethernaut/Level.sol";
66

77
contract FallbackFactory is Level {
8-
function createInstance(address _player) public payable override returns (address) {
9-
_player;
8+
function createInstance(address /* _player */) public payable override returns (address) {
109
Fallback instance = new Fallback();
1110
return address(instance);
1211
}

src/Ethernaut/Fallout/FalloutFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ import "../Ethernaut/Level.sol";
66
import "./Fallout.sol";
77

88
contract FalloutFactory is Level {
9-
function createInstance(address _player) public payable override returns (address) {
10-
_player;
9+
function createInstance(address /* _player */) public payable override returns (address) {
1110
Fallout instance = new Fallout();
1211
return address(instance);
1312
}

src/Ethernaut/Force/ForceFactory.sol

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,11 @@ import "../Ethernaut/Level.sol";
66
import "./Force.sol";
77

88
contract ForceFactory is Level {
9-
function createInstance(address _player) public payable override returns (address) {
10-
_player;
9+
function createInstance(address /* _player */) public payable override returns (address) {
1110
return address(new Force());
1211
}
1312

14-
function validateInstance(address payable _instance, address _player) public view override returns (bool) {
15-
_player;
13+
function validateInstance(address payable _instance, address /* _player */) public view override returns (bool) {
1614
Force instance = Force(_instance);
1715
return address(instance).balance > 0;
1816
}

src/Ethernaut/GatekeeperOne/GatekeeperOneFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ import "../Ethernaut/Level.sol";
66
import "./GatekeeperOne.sol";
77

88
contract GatekeeperOneFactory is Level {
9-
function createInstance(address _player) public payable override returns (address) {
10-
_player;
9+
function createInstance(address /* _player */) public payable override returns (address) {
1110
GatekeeperOne instance = new GatekeeperOne();
1211
return address(instance);
1312
}

src/Ethernaut/GatekeeperThree/GatekeeperThreeFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,7 @@ import "../Ethernaut/Level.sol";
55
import "./GatekeeperThree.sol";
66

77
contract GatekeeperThreeFactory is Level {
8-
function createInstance(address _player) public payable override returns (address) {
9-
_player;
8+
function createInstance(address /* _player */) public payable override returns (address) {
109
GatekeeperThree instance = new GatekeeperThree();
1110
return payable(instance);
1211
}

src/Ethernaut/GatekeeperTwo/GatekeeperTwoFactory.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ import "../Ethernaut/Level.sol";
66
import "./GatekeeperTwo.sol";
77

88
contract GatekeeperTwoFactory is Level {
9-
function createInstance(address _player) public payable override returns (address) {
10-
_player;
9+
function createInstance(address /* _player */) public payable override returns (address) {
1110
GatekeeperTwo instance = new GatekeeperTwo();
1211
return address(instance);
1312
}

0 commit comments

Comments
 (0)