@unilogin/sdk
Version:
SDK is a JS library, that communicates with relayer. SDK allows managing contract, by creating basic contract-calling messages.
7 lines (5 loc) • 302 B
text/typescript
import {UnsignedMessage, ensure, GAS_BASE} from '@unilogin/commons';
import {InsufficientGas} from './errors';
export const ensureSufficientGas = (unsingedMessage: UnsignedMessage) => {
ensure(GAS_BASE < unsingedMessage.safeTxGas, InsufficientGas, `gasLimit should be greater than ${GAS_BASE}`);
};