mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-10 22:36:24 +00:00
parent
5ff4b5a435
commit
be8c5d7534
@ -122,6 +122,9 @@ proc getNetworkForBrowser*(self: Service): NetworkDto =
|
|||||||
proc getNetworkForChat*(self: Service): NetworkDto =
|
proc getNetworkForChat*(self: Service): NetworkDto =
|
||||||
return self.getNetworkForStickers()
|
return self.getNetworkForStickers()
|
||||||
|
|
||||||
|
proc getNetworkForActivityCheck*(self: Service): NetworkDto =
|
||||||
|
return self.getNetworkForStickers()
|
||||||
|
|
||||||
proc getNetworkForCollectibles*(self: Service): NetworkDto =
|
proc getNetworkForCollectibles*(self: Service): NetworkDto =
|
||||||
if self.settingsService.areTestNetworksEnabled():
|
if self.settingsService.areTestNetworksEnabled():
|
||||||
return self.getNetwork(Goerli)
|
return self.getNetwork(Goerli)
|
||||||
|
@ -43,6 +43,7 @@ const fetchDerivedAddressesForMnemonicTask*: Task = proc(argEncoded: string) {.g
|
|||||||
type
|
type
|
||||||
FetchDetailsForAddressesTaskArg* = ref object of QObjectTaskArg
|
FetchDetailsForAddressesTaskArg* = ref object of QObjectTaskArg
|
||||||
uniqueId: string
|
uniqueId: string
|
||||||
|
chainId: int
|
||||||
addresses: seq[string]
|
addresses: seq[string]
|
||||||
|
|
||||||
const fetchDetailsForAddressesTask*: Task = proc(argEncoded: string) {.gcsafe, nimcall.} =
|
const fetchDetailsForAddressesTask*: Task = proc(argEncoded: string) {.gcsafe, nimcall.} =
|
||||||
@ -54,7 +55,7 @@ const fetchDetailsForAddressesTask*: Task = proc(argEncoded: string) {.gcsafe, n
|
|||||||
"error": ""
|
"error": ""
|
||||||
}
|
}
|
||||||
try:
|
try:
|
||||||
let response = status_go_accounts.getAddressDetails(address)
|
let response = status_go_accounts.getAddressDetails(arg.chainId, address)
|
||||||
sleep(250)
|
sleep(250)
|
||||||
data["details"] = response.result
|
data["details"] = response.result
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
|
@ -575,8 +575,10 @@ QtObject:
|
|||||||
))
|
))
|
||||||
|
|
||||||
proc fetchDetailsForAddresses*(self: Service, uniqueId: string, addresses: seq[string]) =
|
proc fetchDetailsForAddresses*(self: Service, uniqueId: string, addresses: seq[string]) =
|
||||||
|
let network = self.networkService.getNetworkForActivityCheck()
|
||||||
let arg = FetchDetailsForAddressesTaskArg(
|
let arg = FetchDetailsForAddressesTaskArg(
|
||||||
uniqueId: uniqueId,
|
uniqueId: uniqueId,
|
||||||
|
chainId: network.chainId,
|
||||||
addresses: addresses,
|
addresses: addresses,
|
||||||
tptr: cast[ByteAddress](fetchDetailsForAddressesTask),
|
tptr: cast[ByteAddress](fetchDetailsForAddressesTask),
|
||||||
vptr: cast[ByteAddress](self.vptr),
|
vptr: cast[ByteAddress](self.vptr),
|
||||||
|
@ -402,8 +402,8 @@ proc getDerivedAddressesForMnemonic*(mnemonic: string, paths: seq[string]): RpcR
|
|||||||
let payload = %* [mnemonic, paths]
|
let payload = %* [mnemonic, paths]
|
||||||
result = core.callPrivateRPC("wallet_getDerivedAddressesForMnemonic", payload)
|
result = core.callPrivateRPC("wallet_getDerivedAddressesForMnemonic", payload)
|
||||||
|
|
||||||
proc getAddressDetails*(address: string,): RpcResponse[JsonNode] {.raises: [Exception].} =
|
proc getAddressDetails*(chainId: int, address: string): RpcResponse[JsonNode] {.raises: [Exception].} =
|
||||||
let payload = %* [address]
|
let payload = %* [chainId, address]
|
||||||
result = core.callPrivateRPC("wallet_getAddressDetails", payload)
|
result = core.callPrivateRPC("wallet_getAddressDetails", payload)
|
||||||
|
|
||||||
proc verifyPassword*(password: string): RpcResponse[JsonNode] {.raises: [Exception].} =
|
proc verifyPassword*(password: string): RpcResponse[JsonNode] {.raises: [Exception].} =
|
||||||
|
2
vendor/status-go
vendored
2
vendor/status-go
vendored
@ -1 +1 @@
|
|||||||
Subproject commit 62e3e9bd62a8634cfee9dc22f62811b944e4e43a
|
Subproject commit 8b05ba6d8b44d441377ea896b0b95d004fc2583c
|
Loading…
x
Reference in New Issue
Block a user