Feature/validator client address getter (#554)
* Added address getter for the client * Might as well bump the version number
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "@nymproject/nym-validator-client",
|
||||
"version": "0.10.0-rc3",
|
||||
"version": "0.10.0-rc4",
|
||||
"description": "A TypeScript client for interacting with smart contracts in Nym validators",
|
||||
"repository": "https://github.com/nymtech/nym",
|
||||
"main": "./dist/index.js",
|
||||
|
||||
@@ -43,6 +43,14 @@ export default class ValidatorClient {
|
||||
return new ValidatorClient(url, queryClient, contractAddress, stakeDenom)
|
||||
}
|
||||
|
||||
public get address(): string {
|
||||
if (this.client instanceof NetClient) {
|
||||
return this.client.clientAddress
|
||||
} else {
|
||||
return ""
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* TODO: re-enable this once we move back to client-side wallets running on people's machines
|
||||
* instead of the web wallet.
|
||||
|
||||
Reference in New Issue
Block a user