fix(@desktop/wallet): Properly return token id value (#11792)
This commit is contained in:
parent
44a59f6740
commit
f8dd1dc811
|
@ -299,9 +299,16 @@ QtObject:
|
|||
error "getTokenID: ActivityEntry is not a transaction"
|
||||
return ""
|
||||
|
||||
var tokenId: Option[TokenID]
|
||||
if self.isInTransactionType():
|
||||
return if self.metadata.tokenIn.isSome(): $self.metadata.tokenIn.unsafeGet().tokenId else: ""
|
||||
return if self.metadata.tokenOut.isSome(): $self.metadata.tokenOut.unsafeGet().tokenId else: ""
|
||||
if self.metadata.tokenIn.isSome():
|
||||
tokenId = self.metadata.tokenIn.unsafeGet().tokenId
|
||||
elif self.metadata.tokenOut.isSome():
|
||||
tokenId = self.metadata.tokenOut.unsafeGet().tokenId
|
||||
|
||||
if tokenId.isSome():
|
||||
return $stint.fromHex(UInt256, string(tokenId.unsafeGet()))
|
||||
return ""
|
||||
|
||||
QtProperty[string] tokenID:
|
||||
read = getTokenID
|
||||
|
|
|
@ -1 +1 @@
|
|||
Subproject commit 078f71a23582e4ffe5e52f75317db0b1ad756542
|
||||
Subproject commit 1f510eae70f00c6daab8eed7395b7fbf4332755e
|
Loading…
Reference in New Issue