Skip to content

Commit d53b4da

Browse files
committed
remove comment codes
1 parent b37b3e5 commit d53b4da

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

extractors/susy/bridge/ergo.go

-10
Original file line numberDiff line numberDiff line change
@@ -129,20 +129,15 @@ func (provider *ErgoToErgoExtractionBridge) ExtractDirectTransferRequest(ctx con
129129
rqId := new(big.Int)
130130
rqId, _ = rqId.SetString(rq.RequestId, 10)
131131
fmt.Println(rqId)
132-
//amount := new(big.Int)
133132
amount, err := strconv.ParseInt(rq.Amount, 10, 64)
134133
bigAmount := big.NewInt(amount)
135134
fmt.Println(bigAmount)
136-
//amount, _ = amount.SetString(rq.Amount, 10)
137135

138136
sourceDecimals := big.NewInt(10)
139137
sourceDecimals.Exp(sourceDecimals, big.NewInt(provider.config.SourceDecimals), nil)
140-
//sourceDecimals := math.Pow(10, float64(provider.config.DestinationDecimals))
141138
destinationDecimals := big.NewInt(10)
142139
destinationDecimals.Exp(destinationDecimals, big.NewInt(provider.config.DestinationDecimals), nil)
143-
//destinationDecimals := math.Pow(10, float64(provider.config.DestinationDecimals))
144140

145-
//newAmount := int64(float64(amount) * sourceDecimals / destinationDecimals)
146141
newAmount := bigAmount.
147142
Mul(bigAmount, destinationDecimals).
148143
Div(bigAmount, sourceDecimals).Int64()
@@ -179,19 +174,14 @@ func (provider *ErgoToErgoExtractionBridge) ExtractReverseTransferRequest(ctx co
179174
rqId := new(big.Int)
180175
rqId, _ = rqId.SetString(rq.RequestId, 10)
181176

182-
//amount := new(big.Int)
183177
amount, err := strconv.ParseInt(rq.Amount, 10, 64)
184178
bigAmount := big.NewInt(amount)
185-
//amount, _ = amount.SetString(rq.Amount, 10)
186179

187180
sourceDecimals := big.NewInt(10)
188181
sourceDecimals.Exp(sourceDecimals, big.NewInt(provider.config.SourceDecimals), nil)
189-
//sourceDecimals := math.Pow(10, float64(provider.config.DestinationDecimals))
190182
destinationDecimals := big.NewInt(10)
191183
destinationDecimals.Exp(destinationDecimals, big.NewInt(provider.config.DestinationDecimals), nil)
192-
//destinationDecimals := math.Pow(10, float64(provider.config.DestinationDecimals))
193184

194-
//newAmount := int64(float64(amount) * sourceDecimals / destinationDecimals)
195185
newAmount := bigAmount.
196186
Mul(bigAmount, destinationDecimals).
197187
Div(bigAmount, sourceDecimals).Int64()

0 commit comments

Comments
 (0)