aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--contracts/extensions/contracts/BalanceThresholdFilter/MixinBalanceThresholdFilterCore.sol8
-rw-r--r--contracts/extensions/contracts/BalanceThresholdFilter/interfaces/IThresholdAsset.sol3
-rw-r--r--contracts/extensions/contracts/BalanceThresholdFilter/mixins/MBalanceThresholdFilterCore.sol4
3 files changed, 11 insertions, 4 deletions
diff --git a/contracts/extensions/contracts/BalanceThresholdFilter/MixinBalanceThresholdFilterCore.sol b/contracts/extensions/contracts/BalanceThresholdFilter/MixinBalanceThresholdFilterCore.sol
index 0ad8ccddf..51dbae8f3 100644
--- a/contracts/extensions/contracts/BalanceThresholdFilter/MixinBalanceThresholdFilterCore.sol
+++ b/contracts/extensions/contracts/BalanceThresholdFilter/MixinBalanceThresholdFilterCore.sol
@@ -53,7 +53,7 @@ contract MixinBalanceThresholdFilterCore is MBalanceThresholdFilterCore {
bytes signedExchangeTransaction,
bytes signature
)
- external
+ external
{
// Validate addresses.
validateBalanceThresholdsOrRevert();
@@ -216,6 +216,7 @@ contract MixinBalanceThresholdFilterCore is MBalanceThresholdFilterCore {
// Step 2/2 Extract addresses to validate based on this selector.
// See ../../utils/ExchangeSelectors/ExchangeSelectors.sol for selectors
+ // solhint-disable no-empty-blocks
switch exchangeFunctionSelector
case 0x297bb70b00000000000000000000000000000000000000000000000000000000 { recordAddressesForBatchFillVariant() } // batchFillOrders
case 0x50dde19000000000000000000000000000000000000000000000000000000000 { recordAddressesForBatchFillVariant() } // batchFillOrdersNoThrow
@@ -245,6 +246,7 @@ contract MixinBalanceThresholdFilterCore is MBalanceThresholdFilterCore {
// 64 -- strlen(INVALID_OR_BLOCKED_EXCHANGE_SELECTOR) rounded up to nearest 32-byte word.
revert(0, 132)
}
+ // solhint-enable no-empty-blocks
///// Validate Recorded Addresses /////
@@ -262,7 +264,9 @@ contract MixinBalanceThresholdFilterCore is MBalanceThresholdFilterCore {
// Validate addresses
let thresholdAssetAddress := sload(THRESHOLD_ASSET_slot)
let thresholdBalance := sload(THRESHOLD_BALANCE_slot)
+ // solhint-disable max-line-length
for {let addressToValidate := addressesToValidateElementPtr} lt(addressToValidate, addressesToValidateElementEndPtr) {addressToValidate := add(addressToValidate, 0x20)} {
+ // solhint-enable max-line-length
// Construct calldata for `THRESHOLD_ASSET.balanceOf`
mstore(freeMemPtr, 0x70a0823100000000000000000000000000000000000000000000000000000000)
mstore(add(freeMemPtr, 0x04), mload(addressToValidate))
@@ -316,4 +320,4 @@ contract MixinBalanceThresholdFilterCore is MBalanceThresholdFilterCore {
///// If we hit this point then all addresses are valid /////
emit ValidatedAddresses(validatedAddresses);
}
-} \ No newline at end of file
+}
diff --git a/contracts/extensions/contracts/BalanceThresholdFilter/interfaces/IThresholdAsset.sol b/contracts/extensions/contracts/BalanceThresholdFilter/interfaces/IThresholdAsset.sol
index 61acaba0a..3e424b9f4 100644
--- a/contracts/extensions/contracts/BalanceThresholdFilter/interfaces/IThresholdAsset.sol
+++ b/contracts/extensions/contracts/BalanceThresholdFilter/interfaces/IThresholdAsset.sol
@@ -18,6 +18,7 @@
pragma solidity 0.4.24;
+
contract IThresholdAsset {
/// @param _owner The address from which the balance will be retrieved
@@ -27,4 +28,4 @@ contract IThresholdAsset {
view
returns (uint256);
-} \ No newline at end of file
+}
diff --git a/contracts/extensions/contracts/BalanceThresholdFilter/mixins/MBalanceThresholdFilterCore.sol b/contracts/extensions/contracts/BalanceThresholdFilter/mixins/MBalanceThresholdFilterCore.sol
index ff0042f58..af7a9453b 100644
--- a/contracts/extensions/contracts/BalanceThresholdFilter/mixins/MBalanceThresholdFilterCore.sol
+++ b/contracts/extensions/contracts/BalanceThresholdFilter/mixins/MBalanceThresholdFilterCore.sol
@@ -26,6 +26,7 @@ import "../interfaces/IThresholdAsset.sol";
contract MBalanceThresholdFilterCore {
// Points to 0x exchange contract
+ // solhint-disable var-name-mixedcase
IExchange internal EXCHANGE;
// The asset that must be held by makers/takers
@@ -33,6 +34,7 @@ contract MBalanceThresholdFilterCore {
// The minimum balance of `THRESHOLD_ASSET` that must be held by makers/takers
uint256 internal THRESHOLD_BALANCE;
+ // solhint-enable var-name-mixedcase
// Addresses that hold at least `THRESHOLD_BALANCE` of `THRESHOLD_ASSET`
event ValidatedAddresses (
@@ -78,4 +80,4 @@ contract MBalanceThresholdFilterCore {
/// If all addresses are valid then this function emits a ValidatedAddresses event, listing all
/// of the addresses whose balance thresholds it checked.
function validateBalanceThresholdsOrRevert() internal;
-} \ No newline at end of file
+}