Skip to content

Latest commit

 

History

History
32 lines (19 loc) · 909 Bytes

rmm-sdk.validatedecimals.md

File metadata and controls

32 lines (19 loc) · 909 Bytes

Home > @primitivefi/rmm-sdk > validateDecimals

validateDecimals() function

This API is provided as a preview for developers and may change based on feedback that we receive. Do not use this API in a production environment.

Checks if amount.decimals is equal to token.decimals.

Signature:

export declare function validateDecimals(amount: Wei, token: Token): void;

Parameters

Parameter Type Description
amount Wei Amount as a Wei class to compare the decimals of to token.decimals.
token Token Token to check the amount against for the same decimals.

Returns:

void

Exceptions

Throws if token decimals are not equal.