Skip to content

Commit

Permalink
Updated comments
Browse files Browse the repository at this point in the history
  • Loading branch information
marcin-cb committed Jun 21, 2024
1 parent c03161c commit 5cec4ce
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 19 deletions.
6 changes: 3 additions & 3 deletions src/coinbase/address.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ export class Address {
/**
* Returns the network ID.
*
* @returns {string} The network ID.
* @returns The network ID.
*/
public getNetworkId(): string {
return this.networkId;
Expand All @@ -28,7 +28,7 @@ export class Address {
/**
* Returns the address ID.
*
* @returns {string} The address ID.
* @returns The address ID.
*/
public getId(): string {
return this.id;
Expand All @@ -37,7 +37,7 @@ export class Address {
/**
* Returns a string representation of the address.
*
* @returns {string} A string representing the address.
* @returns A string representing the address.
*/
public toString(): string {
return `Address { addressId: '${this.getId()}', networkId: '${this.getNetworkId()}' }`;
Expand Down
18 changes: 9 additions & 9 deletions src/coinbase/address/external_address.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export class ExternalAddress extends Address {
* @param amount - The amount of the asset to stake.
* @param assetId - The asset to stake.
* @param options - Additional options for the stake operation.
* @returns {StakingOperation} The stake operation.
* @returns The stake operation.
*/
public async buildStakeOperation(
amount: Amount,
Expand All @@ -35,7 +35,7 @@ export class ExternalAddress extends Address {
* @param amount - The amount of the asset to unstake.
* @param assetId - The asset to unstake.
* @param options - Additional options for the unstake operation.
* @returns {StakingOperation} The unstake operation.
* @returns The unstake operation.
*/
public async buildUnstakeOperation(
amount: Amount,
Expand All @@ -52,7 +52,7 @@ export class ExternalAddress extends Address {
* @param amount - The amount of the asset to claim stake.
* @param assetId - The asset to claim stake.
* @param options - Additional options for the claim stake operation.
* @returns {Transaction} The claim stake operation.
* @returns The claim stake operation.
*/
public async buildClaimStakeOperation(
amount: Amount,
Expand All @@ -68,7 +68,7 @@ export class ExternalAddress extends Address {
*
* @param asset_id - The asset to check the stakeable balance for.
* @param options - Additional options for getting the stakeable balance.
* @returns {string} The stakeable balance.
* @returns The stakeable balance.
*/
public async getStakeableBalance(
asset_id: string,
Expand All @@ -83,7 +83,7 @@ export class ExternalAddress extends Address {
*
* @param asset_id - The asset to check the unstakeable balance for.
* @param options - Additional options for getting the unstakeable balance.
* @returns {string} The unstakeable balance.
* @returns The unstakeable balance.
*/
public async getUnstakeableBalance(
asset_id: string,
Expand All @@ -98,7 +98,7 @@ export class ExternalAddress extends Address {
*
* @param asset_id - The asset to check claimable balance for.
* @param options - Additional options for getting the claimable balance.
* @returns {string} The claimable balance.
* @returns The claimable balance.
*/
public async getClaimableBalance(
asset_id: string,
Expand Down Expand Up @@ -183,7 +183,7 @@ export class ExternalAddress extends Address {
* @param assetId - The asset to lookup balances for.
* @param options - Additional options for the balance lookup.
* @private
* @returns { Map } The different balance types.
* @returns The different balance types.
*/
private async getStakingBalances(
assetId: string,
Expand Down Expand Up @@ -218,7 +218,7 @@ export class ExternalAddress extends Address {
* @param action - The specific action for the staking operation. e.g. stake, unstake, claim_stake
* @param options - Additional options to build a stake operation.
* @private
* @returns {StakingOperation} The staking operation.
* @returns The staking operation.
* @throws {Error} If the supplied input cannot build a valid staking operation.
*/
private async buildStakingOperation(
Expand Down Expand Up @@ -253,7 +253,7 @@ export class ExternalAddress extends Address {
*
* @param options - The supplied options to transform.
* @private
* @returns {Map} The transformed options.
* @returns The transformed options.
*/
private transformStakeOptions(options: CoinbaseExternalAddressStakeOptions): {
[key: string]: string;
Expand Down
14 changes: 7 additions & 7 deletions src/coinbase/address/wallet_address.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ export class WalletAddress extends Address {
/**
* Returns a string representation of the wallet address.
*
* @returns {string} A string representing the wallet address.
* @returns A string representing the wallet address.
*/
public toString(): string {
return `Coinbase:WalletAddress{addressId: '${this.getId()}', networkId: '${this.getNetworkId()}', walletId: '${this.getWalletId()}'}`;
Expand All @@ -50,7 +50,7 @@ export class WalletAddress extends Address {
/**
* Returns the wallet ID.
*
* @returns {string} The wallet ID.
* @returns The wallet ID.
*/
public getWalletId(): string {
return this.model.wallet_id;
Expand All @@ -72,7 +72,7 @@ export class WalletAddress extends Address {
/**
* Returns the list of balances for the address.
*
* @returns {BalanceMap} - The map from asset ID to balance.
* @returns The map from asset ID to balance.
*/
public async listBalances(): Promise<BalanceMap> {
const response = await Coinbase.apiClients.address!.listAddressBalances(
Expand All @@ -86,8 +86,8 @@ export class WalletAddress extends Address {
/**
* Returns the balance of the provided asset.
*
* @param {string} assetId - The asset ID.
* @returns {Decimal} The balance of the asset.
* @param assetId - The asset ID.
* @returns The balance of the asset.
*/
async getBalance(assetId: string): Promise<Decimal> {
const response = await Coinbase.apiClients.address!.getAddressBalance(
Expand All @@ -107,7 +107,7 @@ export class WalletAddress extends Address {
* Requests faucet funds for the address.
* Only supported on testnet networks.
*
* @returns {Promise<FaucetTransaction>} The faucet transaction object.
* @returns The faucet transaction object.
* @throws {InternalError} If the request does not return a transaction hash.
* @throws {Error} If the request fails.
*/
Expand All @@ -122,7 +122,7 @@ export class WalletAddress extends Address {
/**
* Returns all the transfers associated with the address.
*
* @returns {Transfer[]} The list of transfers.
* @returns The list of transfers.
*/
public async listTransfers(): Promise<Transfer[]> {
const transfers: Transfer[] = [];
Expand Down

0 comments on commit 5cec4ce

Please sign in to comment.