Skip to content

Commit ebb8825

Browse files
committed
Remove USDG
1 parent 90aaa2a commit ebb8825

File tree

3 files changed

+4
-13
lines changed

3 files changed

+4
-13
lines changed

pkg/code/common/mint.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ import (
99

1010
"github.com/code-payments/code-server/pkg/code/config"
1111
"github.com/code-payments/code-server/pkg/usdc"
12-
"github.com/code-payments/code-server/pkg/usdg"
1312
"github.com/code-payments/code-server/pkg/usdt"
1413
)
1514

@@ -64,7 +63,7 @@ func StrToQuarks(val string) (int64, error) {
6463

6564
func IsCoreMintUsdStableCoin() bool {
6665
switch CoreMintAccount.PublicKey().ToBase58() {
67-
case usdc.Mint, usdg.Mint, usdt.Mint:
66+
case usdc.Mint, usdt.Mint:
6867
return true
6968
default:
7069
return false

pkg/code/data/external.go

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,6 @@ import (
1212
"github.com/code-payments/code-server/pkg/currency/fixer"
1313
"github.com/code-payments/code-server/pkg/metrics"
1414
"github.com/code-payments/code-server/pkg/usdc"
15-
"github.com/code-payments/code-server/pkg/usdg"
1615
"github.com/code-payments/code-server/pkg/usdt"
1716
)
1817

@@ -52,7 +51,7 @@ func (dp *WebProvider) GetCurrentExchangeRatesFromExternalProviders(ctx context.
5251
var err error
5352

5453
switch config.CoreMintPublicKeyString {
55-
case usdc.Mint, usdg.Mint, usdt.Mint:
54+
case usdc.Mint, usdt.Mint:
5655
coinGeckoRates[string(currency_lib.USD)] = 1.0
5756
default:
5857
coinGeckoData, err := dp.coinGecko.GetCurrentRates(ctx, string(config.CoreMintSymbol))
@@ -85,7 +84,7 @@ func (dp *WebProvider) GetPastExchangeRatesFromExternalProviders(ctx context.Con
8584
ts := t
8685
var err error
8786
switch config.CoreMintPublicKeyString {
88-
case usdc.Mint, usdg.Mint, usdt.Mint:
87+
case usdc.Mint, usdt.Mint:
8988
coinGeckoRates[string(currency_lib.USD)] = 1.0
9089
default:
9190
coinGeckoData, err := dp.coinGecko.GetCurrentRates(ctx, string(config.CoreMintSymbol))
@@ -118,7 +117,7 @@ func computeAllExchangeRates(coreMintRates map[string]float64, usdRates map[stri
118117
return nil, errors.New("usd rate missing")
119118
}
120119
switch config.CoreMintPublicKeyString {
121-
case usdc.Mint, usdg.Mint, usdt.Mint:
120+
case usdc.Mint, usdt.Mint:
122121
coreMintToUsd = 1.0
123122
}
124123

pkg/usdg/usdg.go

Lines changed: 0 additions & 7 deletions
This file was deleted.

0 commit comments

Comments
 (0)