UNPKG

@hashgraph/solo

Version:

An opinionated CLI tool to deploy and manage private Hedera Networks.

25 lines (21 loc) 663 B
// SPDX-License-Identifier: Apache-2.0 /** * Thrown when an arithmetic operation fails due to NaN, Infinity, Division by Zero, or other arithmetic errors. */ export class ArithmeticError extends Error { /** * Constructs a new `ArithmeticError` instance. * * @param message - The error message. * @param cause - The nest error (if any). */ constructor(message: string, cause: Error | any = {}) { super(message); this.name = this.constructor.name; if (cause) { this.cause = cause; } // eslint-disable-next-line unicorn/no-useless-error-capture-stack-trace Error.captureStackTrace(this, this.constructor); } }