Skip to content

Commit 9504cd0

Browse files
committed
style: run forge fmt
1 parent 9fb0b06 commit 9504cd0

File tree

4 files changed

+23
-34
lines changed

4 files changed

+23
-34
lines changed

src/BrokerToken.sol

Lines changed: 19 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,30 @@
11
// SPDX-License-Identifier: GPL-3.0-or-later
22
pragma solidity ^0.8.24;
33

4-
import '@openzeppelin/contracts/token/ERC20/extensions/ERC20Permit.sol';
4+
import "@openzeppelin/contracts/token/ERC20/extensions/ERC20Permit.sol";
55

66
/**
77
* @notice Broker and Canary utility token is a simple ERC20 token with permit functionality.
88
* All the supply is minted to the deployer.
99
*/
1010
contract BrokerToken is ERC20Permit {
11-
/**
12-
* @dev Simple constructor, passing arguments to ERC20Permit and ERC20 constructors.
13-
* Mints the supply to the deployer.
14-
* @param name Name of the Token.
15-
* @param symbol Symbol of the Token.
16-
* @param supply Maximum supply of the Token.
17-
*/
18-
constructor(
19-
string memory name,
20-
string memory symbol,
21-
uint256 supply
22-
) ERC20Permit(name) ERC20(name, symbol) {
23-
_mint(msg.sender, supply);
24-
}
11+
/**
12+
* @dev Simple constructor, passing arguments to ERC20Permit and ERC20 constructors.
13+
* Mints the supply to the deployer.
14+
* @param name Name of the Token.
15+
* @param symbol Symbol of the Token.
16+
* @param supply Maximum supply of the Token.
17+
*/
18+
constructor(string memory name, string memory symbol, uint256 supply) ERC20Permit(name) ERC20(name, symbol) {
19+
_mint(msg.sender, supply);
20+
}
2521

26-
/**
27-
* @notice Return the number of decimals used to get its user representation.
28-
* @dev Overrides ERC20 default value of 18;
29-
* @return uint8 Number of decimals of Token.
30-
*/
31-
function decimals() public pure override returns (uint8) {
32-
return 8;
33-
}
22+
/**
23+
* @notice Return the number of decimals used to get its user representation.
24+
* @dev Overrides ERC20 default value of 18;
25+
* @return uint8 Number of decimals of Token.
26+
*/
27+
function decimals() public pure override returns (uint8) {
28+
return 8;
29+
}
3430
}

src/BrokerTokenFactory.sol

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
// SPDX-License-Identifier: GPL-3.0-or-later
22
pragma solidity ^0.8.24;
33

4-
import '@openzeppelin/contracts/access/Ownable.sol';
5-
import './BrokerToken.sol';
4+
import "@openzeppelin/contracts/access/Ownable.sol";
5+
import "./BrokerToken.sol";
66

77
/**
88
* @title BrokerTokenFactory
@@ -27,11 +27,7 @@ contract BrokerTokenFactory is Ownable {
2727
* @param symbol Symbol of the Token.
2828
* @param supply Maximum supply of the Token.
2929
*/
30-
function createBrokerToken(
31-
string memory name,
32-
string memory symbol,
33-
uint256 supply
34-
) external onlyOwner {
30+
function createBrokerToken(string memory name, string memory symbol, uint256 supply) external onlyOwner {
3531
BrokerToken token = new BrokerToken(name, symbol, supply);
3632
brokerTokens.push(address(token));
3733
emit BrokerTokenCreated(address(token));
@@ -55,4 +51,3 @@ contract BrokerTokenFactory is Ownable {
5551
return brokerTokens[index];
5652
}
5753
}
58-

test/BrokerToken.t.sol

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,3 @@ contract BrokerTokenTest is Test {
2929
assertEq(token.balanceOf(deployer), TOKEN_SUPPLY);
3030
}
3131
}
32-

test/BrokerTokenFactory.t.sol

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ contract BrokerTokenFactoryTest is Test {
2626

2727
// Check if the token was created
2828
assertEq(factory.getBrokerTokensCount(), 1);
29-
29+
3030
address tokenAddress = factory.getBrokerToken(0);
3131
BrokerToken token = BrokerToken(tokenAddress);
3232

@@ -81,4 +81,3 @@ contract BrokerTokenFactoryTest is Test {
8181
assertEq(factory.getBrokerTokensCount(), 2);
8282
}
8383
}
84-

0 commit comments

Comments
 (0)