@mirai/core 0.4.678 → 0.4.679
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -5,21 +5,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
5
5
|
});
|
|
6
6
|
exports.fetchConfig = void 0;
|
|
7
7
|
var _services = require("@mirai/services");
|
|
8
|
-
|
|
9
|
-
const fetchConfig = async function () {
|
|
8
|
+
const fetchConfig = function () {
|
|
10
9
|
let _ref = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
11
10
|
id = _ref.id,
|
|
12
11
|
_ref$type = _ref.type,
|
|
13
12
|
type = _ref$type === void 0 ? 'hotel' : _ref$type;
|
|
14
|
-
return id ?
|
|
13
|
+
return id ? _services.ServiceEngine.get({
|
|
15
14
|
id,
|
|
16
15
|
type
|
|
17
|
-
})
|
|
18
|
-
const _ref2 = error || {},
|
|
19
|
-
config = _ref2.config,
|
|
20
|
-
cookieBanner = _ref2.cookieBanner;
|
|
21
|
-
(0, _trackError.trackError)(config ? 'Error loading json config' : cookieBanner ? 'Error loading cookieBanner' : 'Error loading engine data', (error === null || error === void 0 ? void 0 : error.stack) || JSON.stringify(error), true);
|
|
22
|
-
})) || {} : undefined;
|
|
16
|
+
}) : undefined;
|
|
23
17
|
};
|
|
24
18
|
exports.fetchConfig = fetchConfig;
|
|
25
19
|
//# sourceMappingURL=fetchConfig.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fetchConfig.js","names":["_services","require","
|
|
1
|
+
{"version":3,"file":"fetchConfig.js","names":["_services","require","fetchConfig","_ref","arguments","length","undefined","id","_ref$type","type","ServiceEngine","get","exports"],"sources":["../../src/helpers/fetchConfig.js"],"sourcesContent":["import { ServiceEngine } from '@mirai/services';\n\nexport const fetchConfig = ({ id, type = 'hotel' } = {}) => (id ? ServiceEngine.get({ id, type }) : undefined);\n"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AAEO,MAAMC,WAAW,GAAG,SAAAA,CAAA;EAAA,IAAAC,IAAA,GAAAC,SAAA,CAAAC,MAAA,QAAAD,SAAA,QAAAE,SAAA,GAAAF,SAAA,MAA0B,CAAC,CAAC;IAAzBG,EAAE,GAAAJ,IAAA,CAAFI,EAAE;IAAAC,SAAA,GAAAL,IAAA,CAAEM,IAAI;IAAJA,IAAI,GAAAD,SAAA,cAAG,OAAO,GAAAA,SAAA;EAAA,OAAaD,EAAE,GAAGG,uBAAa,CAACC,GAAG,CAAC;IAAEJ,EAAE;IAAEE;EAAK,CAAC,CAAC,GAAGH,SAAS;AAAA,CAAC;AAACM,OAAA,CAAAV,WAAA,GAAAA,WAAA","ignoreList":[]}
|