Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Commit

Permalink
run go fmt and run gofmt -s
Browse files Browse the repository at this point in the history
  • Loading branch information
nikhilsaraf committed Mar 21, 2019
1 parent d97ebbb commit feee8bb
Show file tree
Hide file tree
Showing 6 changed files with 14 additions and 14 deletions.
4 changes: 2 additions & 2 deletions model/assets.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ const (
FEE Asset = "FEE"
QTUM Asset = "QTUM"
USDT Asset = "USDT"
USDC Asset = "USDC"
USDC Asset = "USDC"
DAO Asset = "DAO"
ETC Asset = "ETC"
ICN Asset = "ICN"
Expand Down Expand Up @@ -110,7 +110,7 @@ var Display = makeAssetConverter(map[Asset]string{
FEE: string(FEE),
QTUM: string(QTUM),
USDT: string(USDT),
USDC: string(USDC),
USDC: string(USDC),
DAO: string(DAO),
ETC: string(ETC),
ICN: string(ICN),
Expand Down
2 changes: 1 addition & 1 deletion plugins/balancedLevelProvider.go
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ func makeBalancedLevelProvider(
shouldRefresh := true

return &balancedLevelProvider{
spread: spread,
spread: spread,
useMaxQuoteInTargetAmountCalc: useMaxQuoteInTargetAmountCalc,
minAmountSpread: minAmountSpread,
maxAmountSpread: maxAmountSpread,
Expand Down
6 changes: 3 additions & 3 deletions plugins/ccxtExchange_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ import (
var supportedExchanges = []string{"binance"}
var emptyAPIKey = api.ExchangeAPIKey{}
var supportedTradingExchanges = map[string]api.ExchangeAPIKey{
"binance": api.ExchangeAPIKey{},
"binance": {},
}

var testOrderConstraints = map[model.TradingPair]model.OrderConstraints{
Expand Down Expand Up @@ -250,8 +250,8 @@ func TestGetOpenOrders_Ccxt(t *testing.T) {
}

tradingPairs := []model.TradingPair{
model.TradingPair{Base: model.XLM, Quote: model.BTC},
model.TradingPair{Base: model.XLM, Quote: model.USDT},
{Base: model.XLM, Quote: model.BTC},
{Base: model.XLM, Quote: model.USDT},
}

for exchangeName, apiKey := range supportedTradingExchanges {
Expand Down
12 changes: 6 additions & 6 deletions plugins/factory.go
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ type StrategyContainer struct {

// strategies is a map of all the strategies available
var strategies = map[string]StrategyContainer{
"buysell": StrategyContainer{
"buysell": {
SortOrder: 1,
Description: "Creates buy and sell offers based on a reference price with a pre-specified liquidity depth",
NeedsConfig: true,
Expand All @@ -51,7 +51,7 @@ var strategies = map[string]StrategyContainer{
return s, nil
},
},
"mirror": StrategyContainer{
"mirror": {
SortOrder: 4,
Description: "Mirrors an orderbook from another exchange by placing the same orders on Stellar",
NeedsConfig: true,
Expand All @@ -68,7 +68,7 @@ var strategies = map[string]StrategyContainer{
return s, nil
},
},
"sell": StrategyContainer{
"sell": {
SortOrder: 0,
Description: "Creates sell offers based on a reference price with a pre-specified liquidity depth",
NeedsConfig: true,
Expand All @@ -85,7 +85,7 @@ var strategies = map[string]StrategyContainer{
return s, nil
},
},
"balanced": StrategyContainer{
"balanced": {
SortOrder: 3,
Description: "Dynamically prices two tokens based on their relative demand",
NeedsConfig: true,
Expand All @@ -98,7 +98,7 @@ var strategies = map[string]StrategyContainer{
return makeBalancedStrategy(strategyFactoryData.sdex, strategyFactoryData.tradingPair, strategyFactoryData.ieif, strategyFactoryData.assetBase, strategyFactoryData.assetQuote, &cfg), nil
},
},
"delete": StrategyContainer{
"delete": {
SortOrder: 2,
Description: "Deletes all orders for the configured orderbook",
NeedsConfig: false,
Expand Down Expand Up @@ -182,7 +182,7 @@ func loadExchanges() {
}

exchanges = &map[string]ExchangeContainer{
"kraken": ExchangeContainer{
"kraken": {
SortOrder: 0,
Description: "Kraken is a popular centralized cryptocurrency exchange",
TradeEnabled: true,
Expand Down
2 changes: 1 addition & 1 deletion plugins/sellSideStrategy.go
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ func (s *sellSideStrategy) UpdateWithOps(offers []horizon.Offer) (ops []build.Tr
// pad the offers so it lines up correctly with numLevelsConsumed.
// alternatively we could chop off the beginning of s.currentLevels but then that affects the logging of levels downstream
for i := 0; i < numLevelsConsumed; i++ {
offers = append([]horizon.Offer{horizon.Offer{}}, offers...)
offers = append([]horizon.Offer{{}}, offers...)
}

// next we want to adjust our remaining offers to be in line with what is desired, creating new offers that may not exist at the end of our existing offers
Expand Down
2 changes: 1 addition & 1 deletion support/networking/endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,4 @@ type Endpoint interface {
GetHandlerFunc() http.HandlerFunc
GetAuthLevel() AuthLevel
GetPath() string
}
}

0 comments on commit feee8bb

Please sign in to comment.