"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getTxType = void 0;
const hw_app_eth_1 = require("@ledgerhq/hw-app-eth");
const fallback = "transfer";
const getTxType = (tx) => {
    if (!tx || !tx.data)
        return fallback;
    const txSelector = `0x${tx.data.toString("hex").substring(0, 8)}`;
    const type = hw_app_eth_1.DAPP_SELECTORS[txSelector];
    if (!type)
        return fallback;
    return type;
};
exports.getTxType = getTxType;
//# sourceMappingURL=txTrackingHelper.js.map