@ledgerhq/live-common
Version:
Common ground for the Ledger Live apps
23 lines • 775 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.findCurrencyExplorer = void 0;
const live_env_1 = require("@ledgerhq/live-env");
const findCurrencyExplorer = (currency) => {
if ((0, live_env_1.getEnv)("SATSTACK") && currency.id === "bitcoin") {
return {
endpoint: (0, live_env_1.getEnv)("EXPLORER_SATSTACK"),
id: "btc",
version: "v3",
};
}
if (currency.explorerId == null) {
console.warn("no explorerId for", currency.id);
}
return {
endpoint: (0, live_env_1.getEnv)("EXPLORER"),
id: currency.explorerId ?? currency.id,
version: "v4",
};
};
exports.findCurrencyExplorer = findCurrencyExplorer;
//# sourceMappingURL=explorer.js.map