mirror of
https://github.com/GMWalletApp/epusdt.git
synced 2026-07-07 10:16:15 +00:00
feat: support TON and USDT Jetton payments
- add TON chain, token, RPC, address normalization, and order matching support - add liteclient scanner with masterchain/shard catch-up and Jetton validation - add TON manual payment verification and focused tests
This commit is contained in:
@@ -8,6 +8,7 @@ import (
|
||||
"github.com/GMWalletApp/epusdt/model/dao"
|
||||
"github.com/GMWalletApp/epusdt/model/mdb"
|
||||
"github.com/GMWalletApp/epusdt/model/request"
|
||||
addressutil "github.com/GMWalletApp/epusdt/util/address"
|
||||
"github.com/dromara/carbon/v2"
|
||||
"github.com/shopspring/decimal"
|
||||
"gorm.io/gorm"
|
||||
@@ -39,9 +40,15 @@ func normalizeLockNetwork(network string) string {
|
||||
|
||||
func normalizeLockAddress(network, address string) string {
|
||||
address = strings.TrimSpace(address)
|
||||
if isEVMNetwork(normalizeLockNetwork(network)) {
|
||||
network = normalizeLockNetwork(network)
|
||||
if isEVMNetwork(network) {
|
||||
return strings.ToLower(address)
|
||||
}
|
||||
if network == mdb.NetworkTon {
|
||||
if raw, err := addressutil.TonRawAddressKey(address); err == nil {
|
||||
return raw
|
||||
}
|
||||
}
|
||||
return address
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user