Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
O
openzeppelin-contracts-upgradeable
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
俞永鹏
openzeppelin-contracts-upgradeable
Commits
458697be
Unverified
Commit
458697be
authored
Feb 23, 2022
by
GitHubPang
Committed by
GitHub
Feb 22, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix typos (#3207)
Fix misspelling in ERC20 contract comments.
parent
af7ec04b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
4 deletions
+4
-4
ERC20FlashMint.sol
contracts/token/ERC20/extensions/ERC20FlashMint.sol
+2
-2
ERC20Snapshot.sol
contracts/token/ERC20/extensions/ERC20Snapshot.sol
+1
-1
ERC20Wrapper.sol
contracts/token/ERC20/extensions/ERC20Wrapper.sol
+1
-1
No files found.
contracts/token/ERC20/extensions/ERC20FlashMint.sol
View file @
458697be
...
...
@@ -21,7 +21,7 @@ abstract contract ERC20FlashMint is ERC20, IERC3156FlashLender {
/**
* @dev Returns the maximum amount of tokens available for loan.
* @param token The address of the token that is requested.
* @return The amont of token that can be loaned.
* @return The amo
u
nt of token that can be loaned.
*/
function maxFlashLoan(address token) public view virtual override returns (uint256) {
return token == address(this) ? type(uint256).max - ERC20.totalSupply() : 0;
...
...
@@ -54,7 +54,7 @@ abstract contract ERC20FlashMint is ERC20, IERC3156FlashLender {
* supported.
* @param amount The amount of tokens to be loaned.
* @param data An arbitrary datafield that is passed to the receiver.
* @return `true` i
s
the flash loan was successful.
* @return `true` i
f
the flash loan was successful.
*/
// This function can reenter, but it doesn't pose a risk because it always preserves the property that the amount
// minted at the beginning is always recovered and burned at the end, or else the entire function will revert.
...
...
contracts/token/ERC20/extensions/ERC20Snapshot.sol
View file @
458697be
...
...
@@ -22,7 +22,7 @@ import "../../../utils/Counters.sol";
* and the account address.
*
* NOTE: Snapshot policy can be customized by overriding the {_getCurrentSnapshotId} method. For example, having it
* return `block.number` will trigger the creation of snapshot at the begin
ing of each new block. When overrid
ding this
* return `block.number` will trigger the creation of snapshot at the begin
ning of each new block. When overri
ding this
* function, be careful about the monotonicity of its result. Non-monotonic snapshot ids will break the contract.
*
* Implementing snapshots for every block using this method will incur significant gas costs. For a gas-efficient
...
...
contracts/token/ERC20/extensions/ERC20Wrapper.sol
View file @
458697be
...
...
@@ -41,7 +41,7 @@ abstract contract ERC20Wrapper is ERC20 {
}
/**
* @dev Mint wrapped token to cover any underlyingTokens that would have been transfered by mistake. Internal
* @dev Mint wrapped token to cover any underlyingTokens that would have been transfer
r
ed by mistake. Internal
* function that can be exposed with access control if desired.
*/
function _recover(address account) internal virtual returns (uint256) {
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment