Skip to content

Commit c2074f9

Browse files
authored
[P1-N04] Fix typos (#1206)
Signed-off-by: Matt Rice <matthewcrice32@gmail.com>
1 parent 766b345 commit c2074f9

File tree

8 files changed

+27
-27
lines changed

8 files changed

+27
-27
lines changed

core/contracts/common/implementation/MultiRole.sol

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -186,8 +186,8 @@ abstract contract MultiRole {
186186
}
187187

188188
/**
189-
* @notice Internal method to initialize a exclusive role, `roleId`, which will be managed by `managingRoleId`.
190-
* `initialMembers` will be immediately added to the role.
189+
* @notice Internal method to initialize an exclusive role, `roleId`, which will be managed by `managingRoleId`.
190+
* `initialMember` will be immediately added to the role.
191191
* @dev Should be called by derived contracts, usually at construction time. Will revert if the role is already
192192
* initialized.
193193
*/

core/contracts/oracle/implementation/IdentifierWhitelist.sol

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,8 @@ contract IdentifierWhitelist is IdentifierWhitelistInterface, Ownable {
2727

2828
/**
2929
* @notice Adds the provided identifier as a supported identifier.
30-
* @dev Price requests using this identifier will be succeed after this call.
31-
* @param identifier uniquely identifies added the identifier. Eg: BTC/UCD.
30+
* @dev Price requests using this identifier will succeed after this call.
31+
* @param identifier unique UTF-8 representation for the feed being added. Eg: BTC/USD.
3232
*/
3333
// TODO(#969) Remove once prettier-plugin-solidity can handle the "override" keyword
3434
// prettier-ignore
@@ -42,7 +42,7 @@ contract IdentifierWhitelist is IdentifierWhitelistInterface, Ownable {
4242
/**
4343
* @notice Removes the identifier from the whitelist.
4444
* @dev Price requests using this identifier will no longer succeed after this call.
45-
* @param identifier uniquely identifies added the identifier. Eg: BTC/UCD.
45+
* @param identifier unique UTF-8 representation for the feed being removed. Eg: BTC/USD.
4646
*/
4747
// TODO(#969) Remove once prettier-plugin-solidity can handle the "override" keyword
4848
// prettier-ignore
@@ -59,7 +59,7 @@ contract IdentifierWhitelist is IdentifierWhitelistInterface, Ownable {
5959

6060
/**
6161
* @notice Checks whether an identifier is on the whitelist.
62-
* @param identifier uniquely identifies added the identifier. Eg: BTC/UCD.
62+
* @param identifier unique UTF-8 representation for the feed being queried. Eg: BTC/USD.
6363
* @return bool if the identifier is supported (or not).
6464
*/
6565
// TODO(#969) Remove once prettier-plugin-solidity can handle the "override" keyword

core/contracts/oracle/implementation/Registry.sol

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,7 +116,7 @@ contract Registry is RegistryInterface, MultiRole {
116116
}
117117

118118
/**
119-
* @notice Removes a party member to the calling contract.
119+
* @notice Removes a party member from the calling contract.
120120
* @dev msg.sender will be used to determine the contract that this party is removed from.
121121
* @param partyAddress address to be removed from the calling contract.
122122
*/

core/contracts/oracle/implementation/ResultComputation.sol

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ library ResultComputation {
5252
* @notice Returns whether the result is resolved, and if so, what value it resolved to.
5353
* @dev `price` should be ignored if `isResolved` is false.
5454
* @param data contains information against which the `minVoteThreshold` is applied.
55-
* @param minVoteThreshold min number of tokens that must have been voted for the result to be valid. Can be
55+
* @param minVoteThreshold min number of tokens that must have voted for the result to be valid. Can be
5656
* used to enforce a minimum voter participation rate, regardless of how the votes are distributed.
5757
* @return isResolved indicates if the price has been resolved correctly.
5858
* @return price the price that the dvm resolved to.
@@ -92,7 +92,7 @@ library ResultComputation {
9292
* @notice Gets the total number of tokens whose votes are considered correct.
9393
* @dev Should only be called after a vote is resolved, i.e., via `getResolvedPrice`.
9494
* @param data contains all votes against which the correctly voted tokens are counted.
95-
* @return FixedPoint.Unsigned which indicates the correctly frequency of the correctly voted tokens.
95+
* @return FixedPoint.Unsigned which indicates the frequency of the correctly voted tokens.
9696
*/
9797
function getTotalCorrectlyVotedTokens(Data storage data) internal view returns (FixedPoint.Unsigned memory) {
9898
return data.voteFrequency[data.currentMode];

core/contracts/oracle/implementation/Voting.sol

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
212212
* @notice Enqueues a request (if a request isn't already present) for the given `identifier`, `time` pair.
213213
* @dev Time must be in the past and the identifier must be supported.
214214
* @param identifier uniquely identifies the price requested. eg BTC/USD (encoded as bytes32) could be requested.
215-
* @param time unix timestamp of for the price request.
215+
* @param time unix timestamp for the price request.
216216
*/
217217
// TODO(#969) Remove once prettier-plugin-solidity can handle the "override" keyword
218218
// prettier-ignore
@@ -276,8 +276,8 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
276276
/**
277277
* @notice Gets the status of a list of price requests, identified by their identifier and time.
278278
* @dev If the status for a particular request is NotRequested, the lastVotingRound will always be 0.
279-
* @param requests array of time PendingRequest which includes a identifier and timestamp for each request.
280-
* @return requestStates A lis, in the same order as the input list, giving the status of each of the specified price requests.
279+
* @param requests array of type PendingRequest which includes an identifier and timestamp for each request.
280+
* @return requestStates A list, in the same order as the input list, giving the status of each of the specified price requests.
281281
*/
282282
function getPriceRequestStatuses(PendingRequest[] memory requests)
283283
public
@@ -311,7 +311,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
311311
* @dev `identifier`, `time` must correspond to a price request that's currently in the commit phase.
312312
* Commits can be changed.
313313
* @param identifier uniquely identifies the committed vote. EG BTC/USD price pair.
314-
* @param time unix timestamp of the price is being voted on.
314+
* @param time unix timestamp of the price being voted on.
315315
* @param hash keccak256 hash of the price you want to vote for and a `int salt`.
316316
*/
317317
// TODO(#969) Remove once prettier-plugin-solidity can handle the "override" keyword
@@ -343,7 +343,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
343343
* @dev The revealed `price` and `salt` must match the latest `hash` that `commitVote()` was called with.
344344
* Only the committer can reveal their vote.
345345
* @param identifier voted on in the commit phase. EG BTC/USD price pair.
346-
* @param time specifies the unix timestamp of the price is being voted on.
346+
* @param time specifies the unix timestamp of the price being voted on.
347347
* @param price voted on during the commit phase.
348348
* @param salt value used to hide the commitment price during the commit phase.
349349
*/
@@ -393,7 +393,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
393393
/**
394394
* @notice commits a vote and stores an encrypted version which can be later decrypted
395395
* to recover the voter's price & salt.
396-
* @dev The encryption mechanism uses encrypt from a signature from a users price key. See `EncryptedSender.sol`
396+
* @dev The encryption mechanism uses encrypt from a signature from a users price key. See `EncryptedStore.sol`
397397
* @param identifier unique price pair identifier. Eg: BTC/USD price pair.
398398
* @param time unix timestamp of for the price request.
399399
* @param hash keccak256 hash of the price you want to vote for and a `int salt`.
@@ -602,7 +602,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
602602
/**
603603
* @notice Resets the inflation rate. Note: this change only applies to rounds that have not yet begun.
604604
* @dev This method is public because calldata structs are not currently supported by solidity.
605-
* @param newInflationRate sets the next rounds inflation rate.
605+
* @param newInflationRate sets the next round's inflation rate.
606606
*/
607607
function setInflationRate(FixedPoint.Unsigned memory newInflationRate) public onlyOwner {
608608
inflationRate = newInflationRate;
@@ -611,7 +611,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
611611
/**
612612
* @notice Resets the Gat percentage. Note: this change only applies to rounds that have not yet begun.
613613
* @dev This method is public because calldata structs are not currently supported by solidity.
614-
* @param newGatPercentage sets the next rounds Gat percentage.
614+
* @param newGatPercentage sets the next round's Gat percentage.
615615
*/
616616
function setGatPercentage(FixedPoint.Unsigned memory newGatPercentage) public onlyOwner {
617617
require(newGatPercentage.isLessThan(1), "GAT percentage must be < 100%");
@@ -708,7 +708,7 @@ contract Voting is Testable, Ownable, OracleInterface, VotingInterface, Encrypte
708708
return FixedPoint.Unsigned(UINT_MAX);
709709
}
710710

711-
// Grab the snaphotted supply from the voting token. It's already scaled by 10**18, so we can directly
711+
// Grab the snapshotted supply from the voting token. It's already scaled by 10**18, so we can directly
712712
// initialize the Unsigned value with the returned uint.
713713
FixedPoint.Unsigned memory snapshottedSupply = FixedPoint.Unsigned(votingToken.totalSupplyAt(snapshotId));
714714

core/contracts/oracle/interfaces/IdentifierWhitelistInterface.sol

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ pragma experimental ABIEncoderV2;
99
interface IdentifierWhitelistInterface {
1010
/**
1111
* @notice Adds the provided identifier as a supported identifier.
12-
* @dev Price requests using this identifier will be succeed after this call.
12+
* @dev Price requests using this identifier will succeed after this call.
1313
* @param identifier bytes32 encoding of the string identifier. Eg: BTC/USD.
1414
*/
1515
function addSupportedIdentifier(bytes32 identifier) external;

core/contracts/oracle/interfaces/OracleInterface.sol

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,15 +10,15 @@ interface OracleInterface {
1010
* @notice Enqueues a request (if a request isn't already present) for the given `identifier`, `time` pair.
1111
* @dev Time must be in the past and the identifier must be supported.
1212
* @param identifier uniquely identifies the price requested. eg BTC/USD (encoded as bytes32) could be requested.
13-
* @param time unix timestamp of for the price request.
13+
* @param time unix timestamp for the price request.
1414
*/
1515
function requestPrice(bytes32 identifier, uint time) external;
1616

1717
/**
1818
* @notice Whether the price for `identifier` and `time` is available.
1919
* @dev Time must be in the past and the identifier must be supported.
2020
* @param identifier uniquely identifies the price requested. eg BTC/USD (encoded as bytes32) could be requested.
21-
* @param time unix timestamp of for the price request.
21+
* @param time unix timestamp for the price request.
2222
* @return bool if the DVM has resolved to a price for the given identifier and timestamp.
2323
*/
2424
function hasPrice(bytes32 identifier, uint time) external view returns (bool);
@@ -27,8 +27,8 @@ interface OracleInterface {
2727
* @notice Gets the price for `identifier` and `time` if it has already been requested and resolved.
2828
* @dev If the price is not available, the method reverts.
2929
* @param identifier uniquely identifies the price requested. eg BTC/USD (encoded as bytes32) could be requested.
30-
* @param time unix timestamp of for the price request.
31-
* @return int representing the resolved price for the given identifer and timestamp.
30+
* @param time unix timestamp for the price request.
31+
* @return int representing the resolved price for the given identifier and timestamp.
3232
*/
3333
function getPrice(bytes32 identifier, uint time) external view returns (int);
3434
}

core/contracts/oracle/interfaces/VotingInterface.sol

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,8 +43,8 @@ abstract contract VotingInterface {
4343
* @dev `identifier`, `time` must correspond to a price request that's currently in the commit phase.
4444
* Commits can be changed.
4545
* @param identifier uniquely identifies the committed vote. EG BTC/USD price pair.
46-
* @param time unix timestamp of the price is being voted on.
47-
* @param hash keccak256 hash of the price you want to vote for and a `int salt`.
46+
* @param time unix timestamp of the price being voted on.
47+
* @param hash keccak256 hash of the price you want to vote for and your random salt.
4848
*/
4949
function commitVote(bytes32 identifier, uint time, bytes32 hash) external virtual;
5050

@@ -53,7 +53,7 @@ abstract contract VotingInterface {
5353
* @dev Using `encryptedVote` is optional. If included then commitment is stored on chain.
5454
* Look at `project-root/common/Constants.js` for the tested maximum number of
5555
* commitments that can fit in one transaction.
56-
* @param commits struct to encapsulate an `identifier`, `time`, `hash` and optional `encryptedVote`.
56+
* @param commits array of structs that encapsulate an `identifier`, `time`, `hash` and optional `encryptedVote`.
5757
*/
5858
function batchCommit(Commitment[] calldata commits) external virtual;
5959

@@ -103,7 +103,7 @@ abstract contract VotingInterface {
103103
* @param voterAddress voter for which rewards will be retrieved. Does not have to be the caller.
104104
* @param roundId the round from which voting rewards will be retrieved from.
105105
* @param toRetrieve array of PendingRequests which rewards are retrieved from.
106-
* @return totalRewardToIssue total amount of rewards returned to the voter.
106+
* @return total amount of rewards returned to the voter.
107107
*/
108108
function retrieveRewards(address voterAddress, uint roundId, PendingRequest[] memory toRetrieve)
109109
public

0 commit comments

Comments
 (0)