"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.validateAddress = void 0;
const address_1 = require("@polkadot/util-crypto/address");
exports.validateAddress = ({ address, message, ss58Format, }) => {
    try {
        const [isValid] = address_1.checkAddress(address, ss58Format || 42);
        return isValid || message;
    }
    catch (error) {
        return message;
    }
};
//# sourceMappingURL=validations.js.map