"use strict";

Object.defineProperty(exports, "__esModule", {
  value: true
});
exports.getCurrency = void 0;
var _locale = require("@mirai/locale");
const getCurrency = function () {
  let _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
    _ref$cookies = _ref.cookies,
    cookies = _ref$cookies === void 0 ? {} : _ref$cookies,
    currency = _ref.currency,
    _ref$urlParams = _ref.urlParams,
    urlParams = _ref$urlParams === void 0 ? {} : _ref$urlParams;
  const forceUri = urlParams.forceUri,
    urlCurrency = urlParams.currency;
  return (forceUri ? urlCurrency : undefined) || cookies.currency || urlCurrency || (currency !== _locale.DEFAULT_CURRENCY ? currency : undefined);
};
exports.getCurrency = getCurrency;
//# sourceMappingURL=getCurrency.js.map