Skip to content

Commit fdd59f7

Browse files
jjgonecryptohav-noms
authored and
hav-noms
committed
Fix Synthetix.isWaitingPeriod() and run format
1 parent 7ab352e commit fdd59f7

16 files changed

+23
-8
lines changed

contracts/AddressResolver.sol

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ pragma solidity 0.4.25;
22

33
import "./Owned.sol";
44

5+
56
contract AddressResolver is Owned {
67
mapping(bytes32 => address) public repository;
78

contracts/ExchangeRates.sol

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import "./SelfDestructible.sol";
77
// AggregatorInterface from Chainlink represents a decentralized pricing network for a single currency key
88
import "chainlink/contracts/interfaces/AggregatorInterface.sol";
99

10+
1011
/**
1112
* @title The repository for exchange rates
1213
*/

contracts/ExchangeState.sol

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ pragma solidity 0.4.25;
22

33
import "./State.sol";
44

5+
56
contract ExchangeState is State {
67
struct ExchangeEntry {
78
bytes32 src;

contracts/Exchanger.sol

+1
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ import "./interfaces/ISynthetix.sol";
99
import "./interfaces/IFeePool.sol";
1010
import "./interfaces/IIssuer.sol";
1111

12+
1213
contract Exchanger is MixinResolver {
1314
using SafeMath for uint;
1415
using SafeDecimalMath for uint;

contracts/FeePool.sol

+2-5
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ import "./FeePoolState.sol";
1616
import "./FeePoolEternalStorage.sol";
1717
import "./DelegateApprovals.sol";
1818

19+
1920
contract FeePool is Proxyable, SelfDestructible, LimitedSetup, MixinResolver {
2021
using SafeMath for uint;
2122
using SafeDecimalMath for uint;
@@ -98,10 +99,7 @@ contract FeePool is Proxyable, SelfDestructible, LimitedSetup, MixinResolver {
9899
}
99100

100101
function feePoolEternalStorage() internal view returns (FeePoolEternalStorage) {
101-
require(
102-
resolver.getAddress("FeePoolEternalStorage") != address(0),
103-
"Missing FeePoolEternalStorage address"
104-
);
102+
require(resolver.getAddress("FeePoolEternalStorage") != address(0), "Missing FeePoolEternalStorage address");
105103
return FeePoolEternalStorage(resolver.getAddress("FeePoolEternalStorage"));
106104
}
107105

@@ -566,7 +564,6 @@ contract FeePool is Proxyable, SelfDestructible, LimitedSetup, MixinResolver {
566564
// return _value;
567565
// }
568566
// return fee;
569-
570567
}
571568

572569
/**

contracts/Issuer.sol

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ import "./interfaces/IFeePool.sol";
88
import "./interfaces/ISynthetixState.sol";
99
import "./interfaces/IExchanger.sol";
1010

11+
1112
contract Issuer is MixinResolver {
1213
using SafeMath for uint;
1314
using SafeDecimalMath for uint;

contracts/MixinResolver.sol

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ pragma solidity 0.4.25;
33
import "./Owned.sol";
44
import "./AddressResolver.sol";
55

6+
67
contract MixinResolver is Owned {
78
AddressResolver public resolver;
89

contracts/MultiCollateralSynth.sol

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ pragma solidity 0.4.25;
1919

2020
import "./Synth.sol";
2121

22+
2223
contract MultiCollateralSynth is Synth {
2324
/* ========== CONSTRUCTOR ========== */
2425
bytes32 public multiCollateralKey;

contracts/PurgeableSynth.sol

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ import "./Synth.sol";
55
import "./interfaces/IExchangeRates.sol";
66
import "./interfaces/ISynthetix.sol";
77

8+
89
contract PurgeableSynth is Synth {
910
using SafeDecimalMath for uint;
1011

contracts/Synth.sol

+1
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ import "./interfaces/IExchanger.sol";
77
import "./interfaces/IIssuer.sol";
88
import "./MixinResolver.sol";
99

10+
1011
contract Synth is ExternStateToken, MixinResolver {
1112
/* ========== STATE VARIABLES ========== */
1213

contracts/SynthetixState.sol

+1
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ import "./LimitedSetup.sol";
4040
import "./SafeDecimalMath.sol";
4141
import "./State.sol";
4242

43+
4344
/**
4445
* @title Synthetix State
4546
* @notice Stores issuance information and preferred currency information of the Synthetix contract.

contracts/interfaces/IDepot.sol

+5
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,22 @@
11
pragma solidity 0.4.25;
22

3+
34
/**
45
* @title Synthetix Depot interface
56
*/
67
contract IDepot {
78
function exchangeEtherForSynths() public payable returns (uint);
9+
810
function exchangeEtherForSynthsAtRate(uint guaranteedRate) external payable returns (uint);
911

1012
function depositSynths(uint amount) external;
13+
1114
function withdrawMyDepositedSynths() external;
1215

1316
// Deprecated ABI for MAINNET. Only used on Testnets
1417
function exchangeEtherForSNX() external payable returns (uint);
18+
1519
function exchangeEtherForSNXAtRate(uint guaranteedRate) external payable returns (uint);
20+
1621
function exchangeSynthsForSNX() external payable returns (uint);
1722
}

contracts/interfaces/IExchangeState.sol

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
pragma solidity 0.4.25;
22

3+
34
interface IExchangeState {
45
function appendExchangeEntry(
56
address account,

contracts/interfaces/IExchanger.sol

+1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
pragma solidity 0.4.25;
22

3+
34
interface IExchanger {
45
function maxSecsLeftInWaitingPeriod(address account, bytes32 currencyKey) external view returns (uint);
56

contracts/interfaces/ISynthetix.sol

+1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ import "../interfaces/IFeePool.sol";
1212
import "../interfaces/IExchangeRates.sol";
1313
import "../Synth.sol";
1414

15+
1516
contract ISynthetix {
1617
// ========== PUBLIC STATE VARIABLES ==========
1718

contracts/test-helpers/MockEtherCollateral.sol

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
1-
21
pragma solidity 0.4.25;
32

43
import "../SafeDecimalMath.sol";
54

5+
66
contract MockEtherCollateral {
77
using SafeMath for uint;
88
using SafeDecimalMath for uint;
99

1010
uint public totalIssuedSynths;
1111

12-
constructor () public { }
12+
constructor() public {}
1313

1414
// Mock openLoan function
1515
function openLoan(uint amount) external {
1616
// Increment totalIssuedSynths
1717
totalIssuedSynths = totalIssuedSynths.add(amount);
1818
}
19-
19+
2020
function closeLoan(uint amount) external {
2121
// Increment totalIssuedSynths
2222
totalIssuedSynths = totalIssuedSynths.sub(amount);

0 commit comments

Comments
 (0)