UNPKG

zephyr-agent

Version:
63 lines (62 loc) • 2.61 kB
"use strict"; var __webpack_require__ = {}; (()=>{ __webpack_require__.d = (exports1, getters, values)=>{ var define = (defs, kind)=>{ for(var key in defs)if (__webpack_require__.o(defs, key) && !__webpack_require__.o(exports1, key)) Object.defineProperty(exports1, key, { enumerable: true, [kind]: defs[key] }); }; define(getters, "get"); define(values, "value"); }; })(); (()=>{ __webpack_require__.o = (obj, prop)=>Object.prototype.hasOwnProperty.call(obj, prop); })(); (()=>{ __webpack_require__.r = (exports1)=>{ if ("u" > typeof Symbol && Symbol.toStringTag) Object.defineProperty(exports1, Symbol.toStringTag, { value: 'Module' }); Object.defineProperty(exports1, '__esModule', { value: true }); }; })(); var __webpack_exports__ = {}; __webpack_require__.r(__webpack_exports__); __webpack_require__.d(__webpack_exports__, { getAppHashCache: ()=>getAppHashCache, removeAppHashCache: ()=>removeAppHashCache, setAppHashCache: ()=>setAppHashCache }); const external_storage_js_namespaceObject = require("./storage.js"); const external_storage_keys_js_namespaceObject = require("./storage-keys.js"); async function setAppHashCache(application_uid, value) { await external_storage_js_namespaceObject.storage; await (0, external_storage_js_namespaceObject.setItem)(`${external_storage_keys_js_namespaceObject.StorageKeys.ze_hash_cache}:${application_uid}`, value, { ttl: 86400000 }); } async function getAppHashCache(application_uid) { await external_storage_js_namespaceObject.storage; return (0, external_storage_js_namespaceObject.getItem)(`${external_storage_keys_js_namespaceObject.StorageKeys.ze_hash_cache}:${application_uid}`); } async function removeAppHashCache(application_uid) { await external_storage_js_namespaceObject.storage; await (0, external_storage_js_namespaceObject.removeItem)(`${external_storage_keys_js_namespaceObject.StorageKeys.ze_hash_cache}:${application_uid}`); } exports.getAppHashCache = __webpack_exports__.getAppHashCache; exports.removeAppHashCache = __webpack_exports__.removeAppHashCache; exports.setAppHashCache = __webpack_exports__.setAppHashCache; for(var __rspack_i in __webpack_exports__)if (-1 === [ "getAppHashCache", "removeAppHashCache", "setAppHashCache" ].indexOf(__rspack_i)) exports[__rspack_i] = __webpack_exports__[__rspack_i]; Object.defineProperty(exports, '__esModule', { value: true }); //# sourceMappingURL=hash-cache.js.map