@shopify/shopify-app-session-storage-mongodb 3.0.3 → 3.0.5
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.
- package/README.md +1 -1
- package/dist/cjs/mongodb.js +99 -0
- package/dist/cjs/mongodb.js.map +1 -0
- package/dist/esm/mongodb.mjs +78 -0
- package/dist/esm/mongodb.mjs.map +1 -0
- package/dist/tsconfig.build.tsbuildinfo +1 -0
- package/package.json +20 -10
- package/build/cjs/mongodb.js +0 -117
- package/build/ts/mongodb.js +0 -182
- package/build/ts/mongodb.js.map +0 -1
- /package/{build → dist}/ts/mongodb.d.ts +0 -0
- /package/{build → dist}/ts/mongodb.d.ts.map +0 -0
package/README.md
CHANGED
|
@@ -27,4 +27,4 @@ const shopify = shopifyApp({
|
|
|
27
27
|
});
|
|
28
28
|
```
|
|
29
29
|
|
|
30
|
-
If you prefer to use your own implementation of a session storage mechanism that is compatible with the `@shopify/shopify-app-express` package, see the [implementing session storage guide](
|
|
30
|
+
If you prefer to use your own implementation of a session storage mechanism that is compatible with the `@shopify/shopify-app-express` package, see the [implementing session storage guide](../shopify-app-session-storage/implementing-session-storage.md).
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var mongodb = require('mongodb');
|
|
4
|
+
var shopifyApi = require('@shopify/shopify-api');
|
|
5
|
+
|
|
6
|
+
function _interopNamespaceDefault(e) {
|
|
7
|
+
var n = Object.create(null);
|
|
8
|
+
if (e) {
|
|
9
|
+
Object.keys(e).forEach(function (k) {
|
|
10
|
+
if (k !== 'default') {
|
|
11
|
+
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
12
|
+
Object.defineProperty(n, k, d.get ? d : {
|
|
13
|
+
enumerable: true,
|
|
14
|
+
get: function () { return e[k]; }
|
|
15
|
+
});
|
|
16
|
+
}
|
|
17
|
+
});
|
|
18
|
+
}
|
|
19
|
+
n.default = e;
|
|
20
|
+
return Object.freeze(n);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
var mongodb__namespace = /*#__PURE__*/_interopNamespaceDefault(mongodb);
|
|
24
|
+
|
|
25
|
+
const defaultMongoDBSessionStorageOptions = {
|
|
26
|
+
sessionCollectionName: 'shopify_sessions',
|
|
27
|
+
};
|
|
28
|
+
class MongoDBSessionStorage {
|
|
29
|
+
static withCredentials(host, dbName, username, password, opts) {
|
|
30
|
+
return new MongoDBSessionStorage(new URL(`mongodb://${encodeURIComponent(username)}:${encodeURIComponent(password)}@${host}/`), dbName, opts);
|
|
31
|
+
}
|
|
32
|
+
constructor(dbUrl, dbName, opts = {}) {
|
|
33
|
+
this.dbUrl = dbUrl;
|
|
34
|
+
this.dbName = dbName;
|
|
35
|
+
if (typeof this.dbUrl === 'string') {
|
|
36
|
+
this.dbUrl = new URL(this.dbUrl);
|
|
37
|
+
}
|
|
38
|
+
this.options = { ...defaultMongoDBSessionStorageOptions, ...opts };
|
|
39
|
+
this.ready = this.init();
|
|
40
|
+
}
|
|
41
|
+
async storeSession(session) {
|
|
42
|
+
await this.ready;
|
|
43
|
+
await this.collection.findOneAndReplace({ id: session.id }, session.toObject(), {
|
|
44
|
+
upsert: true,
|
|
45
|
+
});
|
|
46
|
+
return true;
|
|
47
|
+
}
|
|
48
|
+
async loadSession(id) {
|
|
49
|
+
await this.ready;
|
|
50
|
+
const result = await this.collection.findOne({ id });
|
|
51
|
+
return result ? new shopifyApi.Session(result) : undefined;
|
|
52
|
+
}
|
|
53
|
+
async deleteSession(id) {
|
|
54
|
+
await this.ready;
|
|
55
|
+
await this.collection.deleteOne({ id });
|
|
56
|
+
return true;
|
|
57
|
+
}
|
|
58
|
+
async deleteSessions(ids) {
|
|
59
|
+
await this.ready;
|
|
60
|
+
await this.collection.deleteMany({ id: { $in: ids } });
|
|
61
|
+
return true;
|
|
62
|
+
}
|
|
63
|
+
async findSessionsByShop(shop) {
|
|
64
|
+
await this.ready;
|
|
65
|
+
const rawResults = await this.collection.find({ shop }).toArray();
|
|
66
|
+
if (!rawResults || rawResults?.length === 0)
|
|
67
|
+
return [];
|
|
68
|
+
return rawResults.map((rawResult) => new shopifyApi.Session(rawResult));
|
|
69
|
+
}
|
|
70
|
+
async disconnect() {
|
|
71
|
+
await this.client.close();
|
|
72
|
+
}
|
|
73
|
+
get collection() {
|
|
74
|
+
return this.client
|
|
75
|
+
.db(this.dbName)
|
|
76
|
+
.collection(this.options.sessionCollectionName);
|
|
77
|
+
}
|
|
78
|
+
async init() {
|
|
79
|
+
this.client = new mongodb__namespace.MongoClient(this.dbUrl.toString());
|
|
80
|
+
await this.client.connect();
|
|
81
|
+
await this.client.db().command({ ping: 1 });
|
|
82
|
+
await this.createCollection();
|
|
83
|
+
}
|
|
84
|
+
async hasSessionCollection() {
|
|
85
|
+
const collections = await this.client.db().collections();
|
|
86
|
+
return collections
|
|
87
|
+
.map((collection) => collection.collectionName)
|
|
88
|
+
.includes(this.options.sessionCollectionName);
|
|
89
|
+
}
|
|
90
|
+
async createCollection() {
|
|
91
|
+
const hasSessionCollection = await this.hasSessionCollection();
|
|
92
|
+
if (!hasSessionCollection) {
|
|
93
|
+
await this.client.db().collection(this.options.sessionCollectionName);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
exports.MongoDBSessionStorage = MongoDBSessionStorage;
|
|
99
|
+
//# sourceMappingURL=mongodb.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mongodb.js","sources":["../../../src/mongodb.ts"],"sourcesContent":[null],"names":["Session","mongodb"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;AAOA,MAAM,mCAAmC,GAAiC;AACxE,IAAA,qBAAqB,EAAE,kBAAkB;CAC1C,CAAC;MAEW,qBAAqB,CAAA;IAChC,OAAO,eAAe,CACpB,IAAY,EACZ,MAAc,EACd,QAAgB,EAChB,QAAgB,EAChB,IAA2C,EAAA;QAE3C,OAAO,IAAI,qBAAqB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MAAM,IAAI,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;AAC5B,QAAA,MAAM,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,EAAC,IAAI,EAAE,CAAC,EAAC,CAAC,CAAC;AAC1C,QAAA,MAAM,IAAI,CAAC,gBAAgB,EAAE,CAAC;KAC/B;AAEO,IAAA,MAAM,oBAAoB,GAAA;AAChC,QAAA,MAAM,WAAW,GAAG,MAAM,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC,WAAW,EAAE,CAAC;AACzD,QAAA,OAAO,WAAW;aACf,GAAG,CAAC,CAAC,UAAe,KAAK,UAAU,CAAC,cAAc,CAAC;AACnD,aAAA,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC;KACjD;AAEO,IAAA,MAAM,gBAAgB,GAAA;AAC5B,QAAA,MAAM,oBAAoB,GAAG,MAAM,IAAI,CAAC,oBAAoB,EAAE,CAAC;QAC/D,IAAI,CAAC,oBAAoB,EAAE;AACzB,YAAA,MAAM,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC;SACvE;KACF;AACF;;;;"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import * as mongodb from 'mongodb';
|
|
2
|
+
import { Session } from '@shopify/shopify-api';
|
|
3
|
+
|
|
4
|
+
const defaultMongoDBSessionStorageOptions = {
|
|
5
|
+
sessionCollectionName: 'shopify_sessions',
|
|
6
|
+
};
|
|
7
|
+
class MongoDBSessionStorage {
|
|
8
|
+
static withCredentials(host, dbName, username, password, opts) {
|
|
9
|
+
return new MongoDBSessionStorage(new URL(`mongodb://${encodeURIComponent(username)}:${encodeURIComponent(password)}@${host}/`), dbName, opts);
|
|
10
|
+
}
|
|
11
|
+
constructor(dbUrl, dbName, opts = {}) {
|
|
12
|
+
this.dbUrl = dbUrl;
|
|
13
|
+
this.dbName = dbName;
|
|
14
|
+
if (typeof this.dbUrl === 'string') {
|
|
15
|
+
this.dbUrl = new URL(this.dbUrl);
|
|
16
|
+
}
|
|
17
|
+
this.options = { ...defaultMongoDBSessionStorageOptions, ...opts };
|
|
18
|
+
this.ready = this.init();
|
|
19
|
+
}
|
|
20
|
+
async storeSession(session) {
|
|
21
|
+
await this.ready;
|
|
22
|
+
await this.collection.findOneAndReplace({ id: session.id }, session.toObject(), {
|
|
23
|
+
upsert: true,
|
|
24
|
+
});
|
|
25
|
+
return true;
|
|
26
|
+
}
|
|
27
|
+
async loadSession(id) {
|
|
28
|
+
await this.ready;
|
|
29
|
+
const result = await this.collection.findOne({ id });
|
|
30
|
+
return result ? new Session(result) : undefined;
|
|
31
|
+
}
|
|
32
|
+
async deleteSession(id) {
|
|
33
|
+
await this.ready;
|
|
34
|
+
await this.collection.deleteOne({ id });
|
|
35
|
+
return true;
|
|
36
|
+
}
|
|
37
|
+
async deleteSessions(ids) {
|
|
38
|
+
await this.ready;
|
|
39
|
+
await this.collection.deleteMany({ id: { $in: ids } });
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
async findSessionsByShop(shop) {
|
|
43
|
+
await this.ready;
|
|
44
|
+
const rawResults = await this.collection.find({ shop }).toArray();
|
|
45
|
+
if (!rawResults || rawResults?.length === 0)
|
|
46
|
+
return [];
|
|
47
|
+
return rawResults.map((rawResult) => new Session(rawResult));
|
|
48
|
+
}
|
|
49
|
+
async disconnect() {
|
|
50
|
+
await this.client.close();
|
|
51
|
+
}
|
|
52
|
+
get collection() {
|
|
53
|
+
return this.client
|
|
54
|
+
.db(this.dbName)
|
|
55
|
+
.collection(this.options.sessionCollectionName);
|
|
56
|
+
}
|
|
57
|
+
async init() {
|
|
58
|
+
this.client = new mongodb.MongoClient(this.dbUrl.toString());
|
|
59
|
+
await this.client.connect();
|
|
60
|
+
await this.client.db().command({ ping: 1 });
|
|
61
|
+
await this.createCollection();
|
|
62
|
+
}
|
|
63
|
+
async hasSessionCollection() {
|
|
64
|
+
const collections = await this.client.db().collections();
|
|
65
|
+
return collections
|
|
66
|
+
.map((collection) => collection.collectionName)
|
|
67
|
+
.includes(this.options.sessionCollectionName);
|
|
68
|
+
}
|
|
69
|
+
async createCollection() {
|
|
70
|
+
const hasSessionCollection = await this.hasSessionCollection();
|
|
71
|
+
if (!hasSessionCollection) {
|
|
72
|
+
await this.client.db().collection(this.options.sessionCollectionName);
|
|
73
|
+
}
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
export { MongoDBSessionStorage };
|
|
78
|
+
//# sourceMappingURL=mongodb.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"mongodb.mjs","sources":["../../../src/mongodb.ts"],"sourcesContent":[null],"names":[],"mappings":";;;AAOA,MAAM,mCAAmC,GAAiC;AACxE,IAAA,qBAAqB,EAAE,kBAAkB;CAC1C,CAAC;MAEW,qBAAqB,CAAA;IAChC,OAAO,eAAe,CACpB,IAAY,EACZ,MAAc,EACd,QAAgB,EAChB,QAAgB,EAChB,IAA2C,EAAA;QAE3C,OAAO,IAAI,qBAAqB,CAC9B,IAAI,GAAG,CACL,CAAa,UAAA,EAAA,kBAAkB,CAAC,QAAQ,CAAC,CAAA,CAAA,EAAI,kBAAkB,CAC7D,QAAQ,CACT,CAAA,CAAA,EAAI,IAAI,CAAA,CAAA,CAAG,CACb,EACD,MAAM,EACN,IAAI,CACL,CAAC;KACH;AAOD,IAAA,WAAA,CACU,KAAU,EACV,MAAc,EACtB,OAA8C,EAAE,EAAA;QAFxC,IAAK,CAAA,KAAA,GAAL,KAAK,CAAK;QACV,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;AAGtB,QAAA,IAAI,OAAO,IAAI,CAAC,KAAK,KAAK,QAAQ,EAAE;YAClC,IAAI,CAAC,KAAK,GAAG,IAAI,GAAG,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC;SAClC;QACD,IAAI,C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AAA,MAAM,gBAAgB,GAAA;AAC5B,QAAA,MAAM,oBAAoB,GAAG,MAAM,IAAI,CAAC,oBAAoB,EAAE,CAAC;QAC/D,IAAI,CAAC,oBAAoB,EAAE;AACzB,YAAA,MAAM,IAAI,CAAC,MAAM,CAAC,EAAE,EAAE,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,qBAAqB,CAAC,CAAC;SACvE;KACF;AACF;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"program":{"fileNames":["../../../../../node_modules/typescript/lib/lib.es5.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.d.ts","../../../../../node_modules/typescript/lib/lib.es2016.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.d.ts","../../../../../node_modules/typescript/lib/lib.es2021.d.ts","../../../../../node_modules/typescript/lib/lib.dom.d.ts","../../../../../node_modules/typescript/lib/lib.dom.iterable.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.core.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.collection.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.generator.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.iterable.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.proxy.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.reflect.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.symbol.d.ts","../../../../../node_modules/typescript/lib/lib.es2015.symbol.wellknown.d.ts","../../../../../node_modules/typescript/lib/lib.es2016.array.include.d.ts","../../../../../node_modules/typescript/lib/lib.es2016.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.date.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.object.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.sharedmemory.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2017.typedarrays.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.asyncgenerator.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.asynciterable.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2018.regexp.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.array.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.object.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.symbol.d.ts","../../../../../node_modules/typescript/lib/lib.es2019.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.bigint.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.date.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.sharedmemory.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.symbol.wellknown.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.intl.d.ts","../../../../../node_modules/typescript/lib/lib.es2020.number.d.ts","../../../../../node_modules/typescript/lib/lib.es2021.promise.d.ts","../../../../../node_modules/typescript/lib/lib.es2021.string.d.ts","../../../../../node_modules/typescript/lib/lib.es2021.weakref.d.ts","../../../../../node_modules/typescript/lib/lib.es2021.intl.d.ts","../../../../../node_modules/typescript/lib/lib.esnext.intl.d.ts","../../../../../node_modules/typescript/lib/lib.decorators.d.ts","../../../../../node_modules/typescript/lib/lib.decorators.legacy.d.ts","../../../../../node_modules/tslib/tslib.d.ts","../../../../../node_modules/@types/react/global.d.ts","../../../../../node_modules/csstype/index.d.ts","../../../../../node_modules/@types/prop-types/index.d.ts","../../../../../node_modules/@types/scheduler/tracing.d.ts","../../../../../node_modules/@types/react/index.d.ts","../../../../../node_modules/@types/react/jsx-runtime.d.ts","../../../../../node_modules/@types/node/assert.d.ts","../../../../../node_modules/@types/node/assert/strict.d.ts","../../../../../node_modules/buffer/index.d.ts","../../../../../node_modules/undici-types/header.d.ts","../../../../../node_modules/undici-types/readable.d.ts","../../../../../node_modules/undici-types/file.d.ts","../../../../../node_modules/undici-types/fetch.d.ts","../../../../../node_modules/undici-types/formdata.d.ts","../../../../../node_modules/undici-types/connector.d.ts","../../../../../node_modules/undici-types/client.d.ts","../../../../../node_modules/undici-types/errors.d.ts","../../../../../node_modules/undici-types/dispatcher.d.ts","../../../../../node_modules/undici-types/global-dispatcher.d.ts","../../../../../node_modules/undici-types/global-origin.d.ts","../../../../../node_modules/undici-types/pool-stats.d.ts","../../../../../node_modules/undici-types/pool.d.ts","../../../../../node_modules/undici-types/handlers.d.ts","../../../../../node_modules/undici-types/balanced-pool.d.ts","../../../../../node_modules/undici-types/agent.d.ts","../../../../../node_modules/undici-types/mock-interceptor.d.ts","../../../../../node_modules/undici-types/mock-agent.d.ts","../../../../../node_modules/undici-types/mock-client.d.ts","../../../../../node_modules/undici-types/mock-pool.d.ts","../../../../../node_modules/undici-types/mock-errors.d.ts","../../../../../node_modules/undici-types/proxy-agent.d.ts","../../../../../node_modules/undici-types/api.d.ts","../../../../../node_modules/undici-types/cookies.d.ts","../../../../../node_modules/undici-types/patch.d.ts","../../../../../node_modules/undici-types/filereader.d.ts","../../../../../node_modules/undici-types/diagnostics-channel.d.ts","../../../../../node_modules/undici-types/websocket.d.ts","../../../../../node_modules/undici-types/content-type.d.ts","../../../../../node_modules/undici-types/cache.d.ts","../../../../../node_modules/undici-types/interceptors.d.ts","../../../../../node_modules/undici-types/index.d.ts","../../../../../node_modules/@types/node/globals.d.ts","../../../../../node_modules/@types/node/async_hooks.d.ts","../../../../../node_modules/@types/node/buffer.d.ts","../../../../../node_modules/@types/node/child_process.d.ts","../../../../../node_modules/@types/node/cluster.d.ts","../../../../../node_modules/@types/node/console.d.ts","../../../../../node_modules/@types/node/constants.d.ts","../../../../../node_modules/@types/node/crypto.d.ts","../../../../../node_modules/@types/node/dgram.d.ts","../../../../../node_modules/@types/node/diagnostics_channel.d.ts","../../../../../node_modules/@types/node/dns.d.ts","../../../../../node_modules/@types/node/dns/promises.d.ts","../../../../../node_modules/@types/node/domain.d.ts","../../../../../node_modules/@types/node/dom-events.d.ts","../../../../../node_modules/@types/node/events.d.ts","../../../../../node_modules/@types/node/fs.d.ts","../../../../../node_modules/@types/node/fs/promises.d.ts","../../../../../node_modules/@types/node/http.d.ts","../../../../../node_modules/@types/node/http2.d.ts","../../../../../node_modules/@types/node/https.d.ts","../../../../../node_modules/@types/node/inspector.d.ts","../../../../../node_modules/@types/node/module.d.ts","../../../../../node_modules/@types/node/net.d.ts","../../../../../node_modules/@types/node/os.d.ts","../../../../../node_modules/@types/node/path.d.ts","../../../../../node_modules/@types/node/perf_hooks.d.ts","../../../../../node_modules/@types/node/process.d.ts","../../../../../node_modules/@types/node/punycode.d.ts","../../../../../node_modules/@types/node/querystring.d.ts","../../../../../node_modules/@types/node/readline.d.ts","../../../../../node_modules/@types/node/readline/promises.d.ts","../../../../../node_modules/@types/node/repl.d.ts","../../../../../node_modules/@types/node/sea.d.ts","../../../../../node_modules/@types/node/stream.d.ts","../../../../../node_modules/@types/node/stream/promises.d.ts","../../../../../node_modules/@types/node/stream/consumers.d.ts","../../../../../node_modules/@types/node/stream/web.d.ts","../../../../../node_modules/@types/node/string_decoder.d.ts","../../../../../node_modules/@types/node/test.d.ts","../../../../../node_modules/@types/node/timers.d.ts","../../../../../node_modules/@types/node/timers/promises.d.ts","../../../../../node_modules/@types/node/tls.d.ts","../../../../../node_modules/@types/node/trace_events.d.ts","../../../../../node_modules/@types/node/tty.d.ts","../../../../../node_modules/@types/node/url.d.ts","../../../../../node_modules/@types/node/util.d.ts","../../../../../node_modules/@types/node/v8.d.ts","../../../../../node_modules/@types/node/vm.d.ts","../../../../../node_modules/@types/node/wasi.d.ts","../../../../../node_modules/@types/node/worker_threads.d.ts","../../../../../node_modules/@types/node/zlib.d.ts","../../../../../node_modules/@types/node/globals.global.d.ts","../../../../../node_modules/@types/node/index.d.ts","../../../../../node_modules/bson/bson.d.ts","../../../../../node_modules/mongodb/mongodb.d.ts","../../../shopify-api/dist/ts/rest/types.d.ts","../../../shopify-api/dist/ts/lib/auth/scopes/index.d.ts","../../../shopify-api/dist/ts/lib/types.d.ts","../../../shopify-api/dist/ts/runtime/http/types.d.ts","../../../shopify-api/dist/ts/lib/auth/oauth/types.d.ts","../../../shopify-api/dist/ts/runtime/http/cookies.d.ts","../../../shopify-api/dist/ts/runtime/http/headers.d.ts","../../../shopify-api/dist/ts/runtime/http/utils.d.ts","../../../shopify-api/dist/ts/runtime/http/index.d.ts","../../../shopify-api/dist/ts/lib/session/types.d.ts","../../../shopify-api/dist/ts/lib/session/session.d.ts","../../../shopify-api/dist/ts/lib/billing/types.d.ts","../../../shopify-api/dist/ts/lib/base-types.d.ts","../../../shopify-api/dist/ts/lib/logger/log.d.ts","../../../shopify-api/dist/ts/lib/logger/types.d.ts","../../../shopify-api/dist/ts/lib/logger/index.d.ts","../../../shopify-api/dist/ts/future/flags.d.ts","../../../../api-clients/graphql-client/dist/ts/graphql-client/types.d.ts","../../../../api-clients/graphql-client/dist/ts/graphql-client/graphql-client.d.ts","../../../../api-clients/graphql-client/dist/ts/graphql-client/index.d.ts","../../../../api-clients/graphql-client/dist/ts/graphql-client/utilities.d.ts","../../../../api-clients/graphql-client/dist/ts/api-client-utilities/operation-types.d.ts","../../../../api-clients/graphql-client/dist/ts/api-client-utilities/types.d.ts","../../../../api-clients/graphql-client/dist/ts/api-client-utilities/validations.d.ts","../../../../api-clients/graphql-client/dist/ts/api-client-utilities/api-versions.d.ts","../../../../api-clients/graphql-client/dist/ts/graphql-client/http-fetch.d.ts","../../../../api-clients/graphql-client/dist/ts/api-client-utilities/utilities.d.ts","../../../../api-clients/graphql-client/dist/ts/api-client-utilities/index.d.ts","../../../../api-clients/graphql-client/dist/ts/index.d.ts","../../../../api-clients/admin-api-client/dist/ts/types.d.ts","../../../../api-clients/admin-api-client/dist/ts/graphql/types.d.ts","../../../../api-clients/admin-api-client/dist/ts/graphql/client.d.ts","../../../../api-clients/admin-api-client/dist/ts/graphql/index.d.ts","../../../../api-clients/admin-api-client/dist/ts/rest/types.d.ts","../../../../api-clients/admin-api-client/dist/ts/rest/client.d.ts","../../../../api-clients/admin-api-client/dist/ts/rest/index.d.ts","../../../../api-clients/admin-api-client/dist/ts/index.d.ts","../../../../../node_modules/@shopify/network/build/ts/network.d.ts","../../../../../node_modules/@shopify/network/build/ts/index.d.ts","../../../shopify-api/dist/ts/lib/clients/admin/graphql/client.d.ts","../../../../api-clients/storefront-api-client/dist/ts/types.d.ts","../../../../api-clients/storefront-api-client/dist/ts/storefront-api-client.d.ts","../../../../api-clients/storefront-api-client/dist/ts/index.d.ts","../../../shopify-api/dist/ts/lib/clients/storefront/client.d.ts","../../../shopify-api/dist/ts/lib/clients/graphql_proxy/types.d.ts","../../../shopify-api/dist/ts/runtime/crypto/types.d.ts","../../../shopify-api/dist/ts/runtime/crypto/crypto.d.ts","../../../shopify-api/dist/ts/runtime/crypto/utils.d.ts","../../../shopify-api/dist/ts/runtime/crypto/index.d.ts","../../../shopify-api/dist/ts/runtime/platform/types.d.ts","../../../shopify-api/dist/ts/runtime/platform/runtime-string.d.ts","../../../shopify-api/dist/ts/runtime/platform/index.d.ts","../../../shopify-api/dist/ts/runtime/index.d.ts","../../../shopify-api/dist/ts/lib/clients/admin/types.d.ts","../../../shopify-api/dist/ts/lib/clients/admin/rest/client.d.ts","../../../shopify-api/dist/ts/lib/clients/types.d.ts","../../../shopify-api/dist/ts/lib/clients/index.d.ts","../../../shopify-api/dist/ts/lib/auth/oauth/oauth.d.ts","../../../shopify-api/dist/ts/lib/auth/oauth/nonce.d.ts","../../../shopify-api/dist/ts/lib/auth/oauth/safe-compare.d.ts","../../../shopify-api/dist/ts/lib/auth/oauth/token-exchange.d.ts","../../../shopify-api/dist/ts/lib/auth/types.d.ts","../../../shopify-api/dist/ts/lib/auth/get-embedded-app-url.d.ts","../../../shopify-api/dist/ts/lib/auth/index.d.ts","../../../shopify-api/dist/ts/lib/session/decode-session-token.d.ts","../../../shopify-api/dist/ts/lib/session/index.d.ts","../../../shopify-api/dist/ts/lib/utils/shop-admin-url-helper.d.ts","../../../shopify-api/dist/ts/runtime/types.d.ts","../../../shopify-api/dist/ts/lib/utils/types.d.ts","../../../shopify-api/dist/ts/lib/utils/hmac-validator.d.ts","../../../shopify-api/dist/ts/lib/utils/index.d.ts","../../../shopify-api/dist/ts/lib/webhooks/types.d.ts","../../../shopify-api/dist/ts/lib/webhooks/index.d.ts","../../../shopify-api/dist/ts/lib/billing/index.d.ts","../../../shopify-api/dist/ts/lib/flow/index.d.ts","../../../shopify-api/dist/ts/lib/fulfillment-service/index.d.ts","../../../shopify-api/dist/ts/lib/error.d.ts","../../../shopify-api/dist/ts/lib/session/classes.d.ts","../../../shopify-api/dist/ts/lib/index.d.ts","../../shopify-app-session-storage/dist/ts/types.d.ts","../../shopify-app-session-storage/dist/ts/abstract-migration-engine.d.ts","../../shopify-app-session-storage/dist/ts/rdbms-session-storage-migrator.d.ts","../../shopify-app-session-storage/dist/ts/index.d.ts","../src/mongodb.ts","../../../../../node_modules/@cloudflare/workers-types/index.d.ts","../../../../../node_modules/@jest/expect-utils/build/index.d.ts","../../../../../node_modules/chalk/index.d.ts","../../../../../node_modules/@sinclair/typebox/typebox.d.ts","../../../../../node_modules/@jest/schemas/build/index.d.ts","../../../../../node_modules/pretty-format/build/index.d.ts","../../../../../node_modules/jest-diff/build/index.d.ts","../../../../../node_modules/jest-matcher-utils/build/index.d.ts","../../../../../node_modules/expect/build/index.d.ts","../../../../../node_modules/@types/jest/index.d.ts"],"fileInfos":[{"version":"824cb491a40f7e8fdeb56f1df5edf91b23f3e3ee6b4cde84d4a99be32338faee","affectsGlobalScope":true,"impliedFormat":1},{"version":"45b7ab580deca34ae9729e97c13cfd999df04416a79116c3bfb483804f85ded4","impliedFormat":1},{"version":"3facaf05f0c5fc569c5649dd359892c98a85557e3e0c847964caeb67076f4d75","impliedFormat":1},{"version":"9a68c0c07ae2fa71b44384a839b7b8d81662a236d4b9ac30916718f7510b1b2d","impliedFormat":1},{"version":"5e1c4c362065a6b95ff952c0eab010f04dcd2c3494e813b493ecfd4fcb9fc0d8","impliedFormat":1},{"version":"68d73b4a11549f9c0b7d352d10e91e5dca8faa3322bfb77b661839c42b1ddec7","impliedFormat":1},{"version":"5efce4fc3c29ea84e8928f97adec086e3dc876365e0982cc8479a07954a3efd4","impliedFormat":1},{"version":"feecb1be483ed332fad555aff858affd90a48ab19ba7272ee084704eb7167569","impliedFormat":1},{"version":"87d693a4920d794a73384b3c779cadcb8548ac6945aa7a925832fe2418c9527a","affectsGlobalScope":true,"impliedFormat":1},{"version":"76f838d5d49b65de83bc345c04aa54c62a3cfdb72a477dc0c0fce89a30596c30","affectsGlobalScope":true,"impliedFormat":1},{"version":"138fb588d26538783b78d1e3b2c2cc12d55840b97bf5e08bca7f7a174fbe2f17","affectsGlobalScope":true,"impliedFormat":1},{"version":"dc2df20b1bcdc8c2d34af4926e2c3ab15ffe1160a63e58b7e09833f616efff44","affectsGlobalScope":true,"impliedFormat":1},{"version":"4443e68b35f3332f753eacc66a04ac1d2053b8b035a0e0ac1d455392b5e243b3","affectsGlobalScope":true,"impliedFormat":1},{"version":"bc47685641087c015972a3f072480889f0d6c65515f12bd85222f49a98952ed7","affectsGlobalScope":true,"impliedFormat":1},{"version":"0dc1e7ceda9b8b9b455c3a2d67b0412feab00bd2f66656cd8850e8831b08b537","affectsGlobalScope":true,"impliedFormat":1},{"version":"ce691fb9e5c64efb9547083e4a34091bcbe5bdb41027e310ebba8f7d96a98671","affectsGlobalScope":true,"impliedFormat":1},{"version":"8d697a2a929a5fcb38b7a65594020fcef05ec1630804a33748829c5ff53640d0","affectsGlobalScope":true,"impliedFormat":1},{"version":"4ff2a353abf8a80ee399af572debb8faab2d33ad38c4b4474cff7f26e7653b8d","affectsGlobalScope":true,"impliedFormat":1},{"version":"93495ff27b8746f55d19fcbcdbaccc99fd95f19d057aed1bd2c0cafe1335fbf0","affectsGlobalScope":true,"impliedFormat":1},{"version":"6fc23bb8c3965964be8c597310a2878b53a0306edb71d4b5a4dfe760186bcc01","affectsGlobalScope":true,"impliedFormat":1},{"version":"ea011c76963fb15ef1cdd7ce6a6808b46322c527de2077b6cfdf23ae6f5f9ec7","affectsGlobalScope":true,"impliedFormat":1},{"version":"38f0219c9e23c915ef9790ab1d680440d95419ad264816fa15009a8851e79119","affectsGlobalScope":true,"impliedFormat":1},{"version":"bb42a7797d996412ecdc5b2787720de477103a0b2e53058569069a0e2bae6c7e","affectsGlobalScope":true,"impliedFormat":1},{"version":"4738f2420687fd85629c9efb470793bb753709c2379e5f85bc1815d875ceadcd","affectsGlobalScope":true,"impliedFormat":1},{"version":"2f11ff796926e0832f9ae148008138ad583bd181899ab7dd768a2666700b1893","affectsGlobalScope":true,"impliedFormat":1},{"version":"4de680d5bb41c17f7f68e0419412ca23c98d5749dcaaea1896172f06435891fc","affectsGlobalScope":true,"impliedFormat":1},{"version":"9fc46429fbe091ac5ad2608c657201eb68b6f1b8341bd6d670047d32ed0a88fa","affectsGlobalScope":true,"impliedFormat":1},{"version":"61c37c1de663cf4171e1192466e52c7a382afa58da01b1dc75058f032ddf0839","affectsGlobalScope":true,"impliedFormat":1},{"version":"b541a838a13f9234aba650a825393ffc2292dc0fc87681a5d81ef0c96d281e7a","affectsGlobalScope":true,"impliedFormat":1},{"version":"b20fe0eca9a4e405f1a5ae24a2b3290b37cf7f21eba6cbe4fc3fab979237d4f3","affectsGlobalScope":true,"impliedFormat":1},{"version":"811ec78f7fefcabbda4bfa93b3eb67d9ae166ef95f9bff989d964061cbf81a0c","affectsGlobalScope":true,"impliedFormat":1},{"version":"717937616a17072082152a2ef351cb51f98802fb4b2fdabd32399843875974ca","affectsGlobalScope":true,"impliedFormat":1},{"version":"d7e7d9b7b50e5f22c915b525acc5a49a7a6584cf8f62d0569e557c5cfc4b2ac2","affectsGlobalScope":true,"impliedFormat":1},{"version":"71c37f4c9543f31dfced6c7840e068c5a5aacb7b89111a4364b1d5276b852557","affectsGlobalScope":true,"impliedFormat":1},{"version":"576711e016cf4f1804676043e6a0a5414252560eb57de9faceee34d79798c850","affectsGlobalScope":true,"impliedFormat":1},{"version":"89c1b1281ba7b8a96efc676b11b264de7a8374c5ea1e6617f11880a13fc56dc6","affectsGlobalScope":true,"impliedFormat":1},{"version":"49ed889be54031e1044af0ad2c603d627b8bda8b50c1a68435fe85583901d072","affectsGlobalScope":true,"impliedFormat":1},{"version":"e93d098658ce4f0c8a0779e6cab91d0259efb88a318137f686ad76f8410ca270","affectsGlobalScope":true,"impliedFormat":1},{"version":"063600664504610fe3e99b717a1223f8b1900087fab0b4cad1496a114744f8df","affectsGlobalScope":true,"impliedFormat":1},{"version":"934019d7e3c81950f9a8426d093458b65d5aff2c7c1511233c0fd5b941e608ab","affectsGlobalScope":true,"impliedFormat":1},{"version":"bf14a426dbbf1022d11bd08d6b8e709a2e9d246f0c6c1032f3b2edb9a902adbe","affectsGlobalScope":true,"impliedFormat":1},{"version":"5e07ed3809d48205d5b985642a59f2eba47c402374a7cf8006b686f79efadcbd","affectsGlobalScope":true,"impliedFormat":1},{"version":"2b72d528b2e2fe3c57889ca7baef5e13a56c957b946906d03767c642f386bbc3","affectsGlobalScope":true,"impliedFormat":1},{"version":"8073890e29d2f46fdbc19b8d6d2eb9ea58db9a2052f8640af20baff9afbc8640","affectsGlobalScope":true,"impliedFormat":1},{"version":"368af93f74c9c932edd84c58883e736c9e3d53cec1fe24c0b0ff451f529ceab1","affectsGlobalScope":true,"impliedFormat":1},{"version":"af3dd424cf267428f30ccfc376f47a2c0114546b55c44d8c0f1d57d841e28d74","affectsGlobalScope":true,"impliedFormat":1},{"version":"995c005ab91a498455ea8dfb63aa9f83fa2ea793c3d8aa344be4a1678d06d399","affectsGlobalScope":true,"impliedFormat":1},{"version":"51e547984877a62227042850456de71a5c45e7fe86b7c975c6e68896c86fa23b","affectsGlobalScope":true,"impliedFormat":1},{"version":"956d27abdea9652e8368ce029bb1e0b9174e9678a273529f426df4b3d90abd60","affectsGlobalScope":true,"impliedFormat":1},{"version":"13f6e6380c78e15e140243dc4be2fa546c287c6d61f4729bc2dd7cf449605471","affectsGlobalScope":true,"impliedFormat":1},{"version":"33358442698bb565130f52ba79bfd3d4d484ac85fe33f3cb1759c54d18201393","affectsGlobalScope":true,"impliedFormat":1},{"version":"782dec38049b92d4e85c1585fbea5474a219c6984a35b004963b00beb1aab538","affectsGlobalScope":true,"impliedFormat":1},{"version":"7a1971efcba559ea9002ada4c4e3c925004fb67a755300d53b5edf9399354900","impliedFormat":1},{"version":"55461596dc873b866911ef4e640fae4c39da7ac1fbc7ef5e649cb2f2fb42c349","affectsGlobalScope":true,"impliedFormat":1},{"version":"8a8eb4ebffd85e589a1cc7c178e291626c359543403d58c9cd22b81fab5b1fb9","impliedFormat":1},{"version":"9ed09d4538e25fc79cefc5e7b5bfbae0464f06d2984f19da009f85d13656c211","impliedFormat":1},{"version":"b1bf87add0ccfb88472cd4c6013853d823a7efb791c10bb7a11679526be91eda","impliedFormat":1},{"version":"91f0ee35a4c34ca328a4680a013631acde2688e50e86a49e6aa619f73fd0f7e4","affectsGlobalScope":true,"impliedFormat":1},{"version":"42c169fb8c2d42f4f668c624a9a11e719d5d07dacbebb63cbcf7ef365b0a75b3","impliedFormat":1},{"version":"efc7d584a33fe3422847783d228f315c4cd1afe74bd7cf8e3f0e4c1125129fef","impliedFormat":1},{"version":"7394959e5a741b185456e1ef5d64599c36c60a323207450991e7a42e08911419","impliedFormat":1},{"version":"8e9c23ba78aabc2e0a27033f18737a6df754067731e69dc5f52823957d60a4b6","impliedFormat":1},{"version":"5929864ce17fba74232584d90cb721a89b7ad277220627cc97054ba15a98ea8f","impliedFormat":1},{"version":"7180c03fd3cb6e22f911ce9ba0f8a7008b1a6ddbe88ccf16a9c8140ef9ac1686","impliedFormat":1},{"version":"25c8056edf4314820382a5fdb4bb7816999acdcb929c8f75e3f39473b87e85bc","impliedFormat":1},{"version":"54cb85a47d760da1c13c00add10d26b5118280d44d58e6908d8e89abbd9d7725","impliedFormat":1},{"version":"3e4825171442666d31c845aeb47fcd34b62e14041bb353ae2b874285d78482aa","impliedFormat":1},{"version":"c6fd2c5a395f2432786c9cb8deb870b9b0e8ff7e22c029954fabdd692bff6195","impliedFormat":1},{"version":"a967bfe3ad4e62243eb604bf956101e4c740f5921277c60debaf325c1320bf88","impliedFormat":1},{"version":"e9775e97ac4877aebf963a0289c81abe76d1ec9a2a7778dbe637e5151f25c5f3","impliedFormat":1},{"version":"471e1da5a78350bc55ef8cef24eb3aca6174143c281b8b214ca2beda51f5e04a","impliedFormat":1},{"version":"cadc8aced301244057c4e7e73fbcae534b0f5b12a37b150d80e5a45aa4bebcbd","impliedFormat":1},{"version":"385aab901643aa54e1c36f5ef3107913b10d1b5bb8cbcd933d4263b80a0d7f20","impliedFormat":1},{"version":"9670d44354bab9d9982eca21945686b5c24a3f893db73c0dae0fd74217a4c219","impliedFormat":1},{"version":"db3435f3525cd785bf21ec6769bf8da7e8a776be1a99e2e7efb5f244a2ef5fee","impliedFormat":1},{"version":"c3b170c45fc031db31f782e612adf7314b167e60439d304b49e704010e7bafe5","impliedFormat":1},{"version":"40383ebef22b943d503c6ce2cb2e060282936b952a01bea5f9f493d5fb487cc7","impliedFormat":1},{"version":"4893a895ea92c85345017a04ed427cbd6a1710453338df26881a6019432febdd","impliedFormat":1},{"version":"3a84b7cb891141824bd00ef8a50b6a44596aded4075da937f180c90e362fe5f6","impliedFormat":1},{"version":"13f6f39e12b1518c6650bbb220c8985999020fe0f21d818e28f512b7771d00f9","impliedFormat":1},{"version":"9b5369969f6e7175740bf51223112ff209f94ba43ecd3bb09eefff9fd675624a","impliedFormat":1},{"version":"4fe9e626e7164748e8769bbf74b538e09607f07ed17c2f20af8d680ee49fc1da","impliedFormat":1},{"version":"24515859bc0b836719105bb6cc3d68255042a9f02a6022b3187948b204946bd2","impliedFormat":1},{"version":"33203609eba548914dc83ddf6cadbc0bcb6e8ef89f6d648ca0908ae887f9fcc5","impliedFormat":1},{"version":"0db18c6e78ea846316c012478888f33c11ffadab9efd1cc8bcc12daded7a60b6","impliedFormat":1},{"version":"89167d696a849fce5ca508032aabfe901c0868f833a8625d5a9c6e861ef935d2","impliedFormat":1},{"version":"e53a3c2a9f624d90f24bf4588aacd223e7bec1b9d0d479b68d2f4a9e6011147f","impliedFormat":1},{"version":"339dc5265ee5ed92e536a93a04c4ebbc2128f45eeec6ed29f379e0085283542c","impliedFormat":1},{"version":"9f0a92164925aa37d4a5d9dd3e0134cff8177208dba55fd2310cd74beea40ee2","impliedFormat":1},{"version":"8bfdb79bf1a9d435ec48d9372dc93291161f152c0865b81fc0b2694aedb4578d","impliedFormat":1},{"version":"2e85db9e6fd73cfa3d7f28e0ab6b55417ea18931423bd47b409a96e4a169e8e6","impliedFormat":1},{"version":"c46e079fe54c76f95c67fb89081b3e399da2c7d109e7dca8e4b58d83e332e605","impliedFormat":1},{"version":"d32275be3546f252e3ad33976caf8c5e842c09cb87d468cb40d5f4cf092d1acc","impliedFormat":1},{"version":"4a0c3504813a3289f7fb1115db13967c8e004aa8e4f8a9021b95285502221bd1","impliedFormat":1},{"version":"a14ed46fa3f5ffc7a8336b497cd07b45c2084213aaca933a22443fcb2eef0d07","affectsGlobalScope":true,"impliedFormat":1},{"version":"cce1f5f86974c1e916ec4a8cab6eec9aa8e31e8148845bf07fbaa8e1d97b1a2c","impliedFormat":1},{"version":"7fd7fcbf021a5845bdd9397d4649fcf2fe17152d2098140fc723099a215d19ad","affectsGlobalScope":true,"impliedFormat":1},{"version":"df3389f71a71a38bc931aaf1ef97a65fada98f0a27f19dd12f8b8de2b0f4e461","impliedFormat":1},{"version":"d69a3298a197fe5d59edba0ec23b4abf2c8e7b8c6718eac97833633cd664e4c9","impliedFormat":1},{"version":"a9544f6f8af0d046565e8dde585502698ebc99eef28b715bad7c2bded62e4a32","affectsGlobalScope":true,"impliedFormat":1},{"version":"a40826e8476694e90da94aa008283a7de50d1dafd37beada623863f1901cb7fb","impliedFormat":1},{"version":"8b809082dfeffc8cc4f3b9c59f55c0ff52ba12f5ae0766cb5c35deee83b8552e","affectsGlobalScope":true,"impliedFormat":1},{"version":"bd3f5d05b6b5e4bfcea7739a45f3ffb4a7f4a3442ba7baf93e0200799285b8f1","impliedFormat":1},{"version":"4c775c2fccabf49483c03cd5e3673f87c1ffb6079d98e7b81089c3def79e29c6","impliedFormat":1},{"version":"d4f9d3ae2fe1ae199e1c832cca2c44f45e0b305dfa2808afdd51249b6f4a5163","impliedFormat":1},{"version":"7525257b4aa35efc7a1bbc00f205a9a96c4e4ab791da90db41b77938c4e0c18e","impliedFormat":1},{"version":"b7fe70be794e13d1b7940e318b8770cd1fb3eced7707805318a2e3aaac2c3e9e","impliedFormat":1},{"version":"ee1ee365d88c4c6c0c0a5a5701d66ebc27ccd0bcfcfaa482c6e2e7fe7b98edf7","affectsGlobalScope":true,"impliedFormat":1},{"version":"9c611eff81287837680c1f4496daf9e737d6f3a1ff17752207814b8f8e1265af","affectsGlobalScope":true,"impliedFormat":1},{"version":"fe1fd6afdfe77976d4c702f3746c05fb05a7e566845c890e0e970fe9376d6a90","impliedFormat":1},{"version":"b5d4e3e524f2eead4519c8e819eaf7fa44a27c22418eff1b7b2d0ebc5fdc510d","impliedFormat":1},{"version":"afb1701fd4be413a8a5a88df6befdd4510c30a31372c07a4138facf61594c66d","impliedFormat":1},{"version":"9bd8e5984676cf28ebffcc65620b4ab5cb38ab2ec0aac0825df8568856895653","impliedFormat":1},{"version":"396a8939b5e177542bdf9b5262b4eee85d29851b2d57681fa9d7eae30e225830","impliedFormat":1},{"version":"5e8dc64e7e68b2b3ea52ed685cf85239e0d5fb9df31aabc94370c6bc7e19077b","impliedFormat":1},{"version":"ea455cc68871b049bcecd9f56d4cf27b852d6dafd5e3b54468ca87cc11604e4d","affectsGlobalScope":true,"impliedFormat":1},{"version":"c07146dbbbd8b347241b5df250a51e48f2d7bef19b1e187b1a3f20c849988ff1","impliedFormat":1},{"version":"45b1053e691c5af9bfe85060a3e1542835f8d84a7e6e2e77ca305251eda0cb3c","impliedFormat":1},{"version":"0f05c06ff6196958d76b865ae17245b52d8fe01773626ac3c43214a2458ea7b7","impliedFormat":1},{"version":"ae5507fc333d637dec9f37c6b3f4d423105421ea2820a64818de55db85214d66","affectsGlobalScope":true,"impliedFormat":1},{"version":"46755a4afc53df75f0bfce72259fb971daac826b0cdd8c4eaccad2755a817403","affectsGlobalScope":true,"impliedFormat":1},{"version":"8abd0566d2854c4bd1c5e48e05df5c74927187f1541e6770001d9637ac41542e","impliedFormat":1},{"version":"54e854615c4eafbdd3fd7688bd02a3aafd0ccf0e87c98f79d3e9109f047ce6b8","impliedFormat":1},{"version":"d8dba11dc34d50cb4202de5effa9a1b296d7a2f4a029eec871f894bddfb6430d","impliedFormat":1},{"version":"8b71dd18e7e63b6f991b511a201fad7c3bf8d1e0dd98acb5e3d844f335a73634","impliedFormat":1},{"version":"01d8e1419c84affad359cc240b2b551fb9812b450b4d3d456b64cda8102d4f60","impliedFormat":1},{"version":"9eece5e586312581ccd106d4853e861aaaa1a39f8e3ea672b8c3847eedd12f6e","impliedFormat":1},{"version":"8221b00f271cf7f535a8eeec03b0f80f0929c7a16116e2d2df089b41066de69b","impliedFormat":1},{"version":"269929a24b2816343a178008ac9ae9248304d92a8ba8e233055e0ed6dbe6ef71","impliedFormat":1},{"version":"93452d394fdd1dc551ec62f5042366f011a00d342d36d50793b3529bfc9bd633","impliedFormat":1},{"version":"7fa32887f8a97909fca35ebba3740f8caf8df146618d8fff957a3f89f67a2f6a","impliedFormat":1},{"version":"9a9634296cca836c3308923ba7aa094fa6ed76bb1e366d8ddcf5c65888ab1024","impliedFormat":1},{"version":"bddce945d552a963c9733db106b17a25474eefcab7fc990157a2134ef55d4954","affectsGlobalScope":true,"impliedFormat":1},{"version":"7052b7b0c3829df3b4985bab2fd74531074b4835d5a7b263b75c82f0916ad62f","affectsGlobalScope":true,"impliedFormat":1},{"version":"aa34c3aa493d1c699601027c441b9664547c3024f9dbab1639df7701d63d18fa","impliedFormat":1},{"version":"4b55240c2a03b2c71e98a7fc528b16136faa762211c92e781a01c37821915ea6","impliedFormat":1},{"version":"7c651f8dce91a927ab62925e73f190763574c46098f2b11fb8ddc1b147a6709a","impliedFormat":1},{"version":"7440ab60f4cb031812940cc38166b8bb6fbf2540cfe599f87c41c08011f0c1df","impliedFormat":1},{"version":"94c086dff8dbc5998749326bc69b520e8e4273fb5b7b58b50e0210e0885dfcde","affectsGlobalScope":true,"impliedFormat":1},{"version":"f5b5dc128973498b75f52b1b8c2d5f8629869104899733ae485100c2309b4c12","affectsGlobalScope":true,"impliedFormat":1},{"version":"ebe5facd12fd7745cda5f4bc3319f91fb29dc1f96e57e9c6f8b260a7cc5b67ee","impliedFormat":1},{"version":"79bad8541d5779c85e82a9fb119c1fe06af77a71cc40f869d62ad379473d4b75","impliedFormat":1},{"version":"21c56c6e8eeacef15f63f373a29fab6a2b36e4705be7a528aae8c51469e2737b","impliedFormat":1},{"version":"629d20681ca284d9e38c0a019f647108f5fe02f9c59ac164d56f5694fc3faf4d","affectsGlobalScope":true,"impliedFormat":1},{"version":"e7dbf5716d76846c7522e910896c5747b6df1abd538fee8f5291bdc843461795","impliedFormat":1},{"version":"ab9b9a36e5284fd8d3bf2f7d5fcbc60052f25f27e4d20954782099282c60d23e","affectsGlobalScope":true,"impliedFormat":1},{"version":"a42be67ed1ddaec743582f41fc219db96a1b69719fccac6d1464321178d610fc","impliedFormat":1},{"version":"7cc1b4e7390d449fc3054863cd0d5acc48355b45586eb321d9156e50b6f4d50f","impliedFormat":1},{"version":"01a8a1325d1e97da3be1876c80672367ae62037071cfb32aac61a6d420acbe74","impliedFormat":1},{"version":"e93f8133554a84d6580720287dfc378552b108fe611701057db5dade7b66fe97","impliedFormat":1},{"version":"b7309a9e9a9b7422485de2bc6ff6aef4454e2487f911eae4ec20c2f756ee1980","impliedFormat":1},{"version":"78317ae0c828eb9370daf4c1f8f673f3a829f985bbe62e1b72d7e90cdc045a46","impliedFormat":1},{"version":"2a8b2600042e9271b9128a7fa29a8854b6940a05e79c4314c7da463f43e1a3e2","impliedFormat":1},{"version":"e45d5693f67e24f6f33cc4a2657edda5bf88f10aceeba40181960e2ea0163860","impliedFormat":1},{"version":"eacbd825bc63e1cf7ed2ccff0b01868cd45de53cb01b20102b18e0f44fe48045","impliedFormat":1},{"version":"52c486e59089844cb1cd5c23e364cfb76024cb20462275d257f3a759ee7f06fb","impliedFormat":1},{"version":"48586d073b46580a94435234f128545cf7bcfeb2bfebb9dd1f510ad66f535b28","impliedFormat":1},{"version":"cb40fade754d840a1906e1c841ba45aebc04890983a60fab0c73c59d278aadf1","impliedFormat":1},{"version":"351e9ad9b23729759b4e4849a585fd6e8a0a99cfc4af53aceff6c62d10f0682e","impliedFormat":1},{"version":"b75065b32c720334495c32612ee0594db1cdeec431d383b3cbda0c7dba5445ac","impliedFormat":1},{"version":"4f622be3cb6e8d6c3c67e504aaf7f6860bf00057f866b495fabcca4ce25ec6e2","impliedFormat":1},{"version":"58c688bfaf13ae26967fe582235da97015e5121f24f3a11d1be3496aebffbc41","impliedFormat":1},{"version":"b045ccacbd5f5fcb97bf777a510c0ed2c8e6cf032b06f7d9d9666c9457682e87","impliedFormat":1},{"version":"fcf4e506a4b6fc2fe83ecaf6ecfb938fd142037c329adb430308e9c3cbd2c37e","impliedFormat":1},{"version":"414942cddfbe4cd724cf55a726eb280285c0f42c7146f58be470e3d6d29d38fe","impliedFormat":1},{"version":"a285b6c595ec9ba834f639c629dd0d4f17fece1b8b485413d98a60d90d4ec87d","impliedFormat":1},{"version":"919c1a43ee4901781a129d9c9f4a49a474d3f085fa688487a9626a06e8514068","impliedFormat":1},{"version":"cd842aa849dcd6d071d1c842e9849fbf8c6e1066da917a547599e91928f72d05","impliedFormat":1},{"version":"f9dc9fd4236f5b5950ca482f8f94dc13160ae06ee69f8e7af5f4b9e5c47bde4f","impliedFormat":1},{"version":"b85d42b044c3706c4a8f7ce187678108f52858cd30244aa65816818ea2ac523a","impliedFormat":1},{"version":"91ada00797313602bd743e3c389da035521349d1a9ba5a7907b98a21458c0d07","impliedFormat":1},{"version":"24ba31decd882aa7f5adf9208f88c5dc2d64cf1121cd9bc33255fcd183080973","impliedFormat":1},{"version":"801ff78aad3b6dcb84e390ff5ff1190569b2532da7d234ae1193db2c5af7d117","impliedFormat":1},{"version":"504e97bde536d03afd59e0907abf04c879e387d442932274627d4dbbf55779c1","impliedFormat":1},{"version":"cd9e0beb3736dead10eb3c6bad8d852f2910d39786b9ae45603b3c2628aa7c5f","impliedFormat":1},{"version":"4c0d93f69f95d273cea31e7680e30d06945c2dbe40f905f95577b48961f9f790","impliedFormat":1},{"version":"05e61ea8def7d60c293f166518091b55c5d12e68bbf06c18192d5ca260a002d3","impliedFormat":1},{"version":"cb1d14294b25c695cf3c3a71e23f028eaf18f0c795f85b2d486ef0060a3bf8f2","impliedFormat":1},{"version":"43d897c85406cd5e7f3b4e2ee7e1d7e1040bc9e63f7b820db52e1e005c218d97","impliedFormat":1},{"version":"136d8c587087fa215d24b7b22b1f0c31578b2dfbfec35c4c376f4b28b3185e54","impliedFormat":1},{"version":"d6517e73cb1c442253cf227980514480722030149a3071ab5a835a4b8393e3a9","impliedFormat":1},{"version":"207544ff4e6e3685098bdf013673db192b0a5788dd780781baf40276b3f4aec6","impliedFormat":1},{"version":"196eebfc5cfeadd8af67de300442aa2518707bcf02d5ae3ae9a19832b1b9e1e9","impliedFormat":1},{"version":"058a9a128cc87b531fce7bf705dfda32fe77bd7f5f83dcebbe502b2bfadb2e82","impliedFormat":1},{"version":"e460d2eedf27885d96c49e9848b447564faec0ee251b89038d1624ac3ef81088","impliedFormat":1},{"version":"01a8022774597128bb9863f24db4eb504a9d7272ea6ff335db3892eb8242582f","impliedFormat":1},{"version":"96f6781abbd4903e137f8dd59440d2c77e4ca903a2226217fa90a83d09a3e772","impliedFormat":1},{"version":"46439fd047f993161368be2cbcc7bf13bc3ef45bb428d01301c6de72c7b12eda","impliedFormat":1},{"version":"a625df2d02a0edb8d6a90a3d76fcb81050d0e88e42ec48857f5fec76ce8ba01e","impliedFormat":1},{"version":"45d382afe9eebdd510b592cd41e7e452297ed9a4899ffdc8f6804dc408149a5f","impliedFormat":1},{"version":"31174d359b227d6b0810b1b7a017cca56bd6829f4966a124592b83f6bb6952f8","impliedFormat":1},{"version":"aca0f5b02e5a3d6ae9f53d04c9deb4b71ccbcdccc3d2ca7f1ac26ee1be7ff67e","impliedFormat":1},{"version":"d5b99b4c60801ab75f795853d783402168f86ee901b8b09d719b8183d024185f","impliedFormat":1},{"version":"83cc02852e1f62fe3b04d96daa531763b56f190841474bcc1c167b7e51d69c61","impliedFormat":1},{"version":"73280fa95301c041729c326916fb95b6e1e3ca5ede1cd3fae0f81cf3529eca24","impliedFormat":1},{"version":"37fba046a1696ad1aae3ff9fa3f525a9228f0f04c8d65ca7326ace3d44a370cd","impliedFormat":1},{"version":"0d3ab3a71527932312143161619b8d34d10f9d90c7cf83d44db2914a39c860a7","impliedFormat":1},{"version":"310dd22e86859518b72aa18158aa42ea542528c53517177491e18a3b19515d24","impliedFormat":1},{"version":"7bd663e45a60195fafcd826f69c2c2ce289417babc2b2080573a850b0c7b159a","impliedFormat":1},{"version":"c82f4f97d14479c13633874cffe2e8a095e03de808d921f83f933e445fbf7f37","impliedFormat":1},{"version":"d2e90744cd417fdaff47eb9835fa5cd16b7737cb2d71a844312e628652c1e093","impliedFormat":1},{"version":"117217e9f4c8e59500965f86f6829a125edc8c6484c5db26fe2d7f68eb89c520","impliedFormat":1},{"version":"aa71fa032cd702f309035fc5e74b81986c2882e3860f470d79a4791b0ee56ded","impliedFormat":1},{"version":"45cd55ed05e66379e75dc8ebb29787dbb56301a8373dd2df1642d60bc1fdfab9","impliedFormat":1},{"version":"f30d34b2234d000489009c1e69469434e5dcacea461c5353b85a5ea602563709","impliedFormat":1},{"version":"ccf78f2be590261b2ddfc4b4afab4755b0a2c4b707cb79d0952b6bb0c965c4af","impliedFormat":1},{"version":"0bcca674a7f8af915f6c5ebccc71f4848cc0a19cbdd5d367ffdab5999278aad4","impliedFormat":1},{"version":"d7de47b7fd28ffaab21ec64344d796aff4bbb7100e41f074c3bdfee5698c5cdc","impliedFormat":1},{"version":"f01b7030872b6347f9819a2244652ed0788779998f5a404848e43fd2bc284b95","impliedFormat":1},{"version":"f459de4d8c170983d768cd9bf15e385480308e8791ed715264a4bb1bd28a163f","impliedFormat":1},{"version":"283732d2744760f54863d2d1c5ccff08125e1c4fa4421ff67f8ac8312893a5f8","impliedFormat":1},{"version":"07f72a2f1b89c2b44790c761daaa394958bcad2568981b5b7c9beb5e7b019105","impliedFormat":1},{"version":"f7f407bb61d59926df1c7e46b7576d26fc04ab5ceccdde14ba75e205768173b2","impliedFormat":1},{"version":"9fec850d899d1c3cbb1e7b199bf5a10bd03a1f595ef9ffb26ac0dc2a21904e33","impliedFormat":1},{"version":"8015b8ec1b5bd548e92d4f88653060e5c4ddbdb45d03d7ffc58f58ee24d5a921","impliedFormat":1},{"version":"d2664366328af0236ef4db8b54da035b5b2e2b1361f591af8319f7a62b3e8061","impliedFormat":1},{"version":"38f30bae10354806e815bd88e356cd2667b400fae3840716ca0731e1676db737","impliedFormat":1},{"version":"81648ce510a7740b91e79cecd91936ee6922f010d685d587d2f61cadc5246bd1","impliedFormat":1},{"version":"c84d2aa558539e4e846971a75be6a03058ce670f9a49c140cd9842d45094f7b5","impliedFormat":1},{"version":"5bc339f28db8858c1a59d55af887a7f4e52bede25e30b662667cb635107047ec","impliedFormat":1},{"version":"a1157f7e5886018317e1d3b9b1181612e49f9766b3886f2c046501ab7fb304ee","impliedFormat":1},{"version":"ecedacc51732eacd3cefe6a672ac90628fca45f553f06116f3ff6cdbf64aa6d9","impliedFormat":1},{"version":"d7b654bf440d9f4e1b64e09ffc4f1c941aa50ac6389efe74c32b1a4d36dd923d","impliedFormat":1},{"version":"dff09bcf9254cf54a475efa423d4f1db27ef54f14e911632868b243c707a3e6a","impliedFormat":1},{"version":"dab56ae47c2ec7051feafed0b4bebec1950c20d995ca3828144373babd708ff3","impliedFormat":1},{"version":"896cae3b369fc03789ec2506dc6cc967026fc1c812890ce50ca89a19e5ae66ef","impliedFormat":1},{"version":"634a163cc8202061f984bdf9e5349425ed414b0233ce0e4865440259362d7a97","impliedFormat":1},{"version":"fccc07bf84c61b04695f8235d9e0945583d9b4edfaeee156cb8e1531b7e109ea","impliedFormat":1},{"version":"5523de77e01ad20927ef45dfe246cca902577ddf3deadaa913f4880324a356a7","impliedFormat":1},{"version":"f51cd30d71a743daf51e6bfa0e484286534900de73035e78a4c6bd6c52dc5b5c","impliedFormat":1},{"version":"dde9f75371884d2be3d2e3a01286f1c501979162320529d3c25cf852d04f31e4","impliedFormat":1},{"version":"809796eb4b7225ff86520b529e0d0949f941904adc42a650824181a5a2d6fe0e","impliedFormat":1},{"version":"f2b4812e1fab308341a66515ee64e57da1978a48adf8f8acd2de3a4cfc05c732","signature":"8889dc95aee3670945cb219549508c8f4cc71c5ac6b5ddb1af27fd75c67b87e1","impliedFormat":1},{"version":"16bd138ac5722a4aeb9a5f4bde6c6609c123d6bda5f95e8210a8251c0585ae05","affectsGlobalScope":true,"impliedFormat":1},{"version":"cdcc132f207d097d7d3aa75615ab9a2e71d6a478162dde8b67f88ea19f3e54de","impliedFormat":1},{"version":"0d14fa22c41fdc7277e6f71473b20ebc07f40f00e38875142335d5b63cdfc9d2","impliedFormat":1},{"version":"c085e9aa62d1ae1375794c1fb927a445fa105fed891a7e24edbb1c3300f7384a","impliedFormat":1},{"version":"f315e1e65a1f80992f0509e84e4ae2df15ecd9ef73df975f7c98813b71e4c8da","impliedFormat":1},{"version":"5b9586e9b0b6322e5bfbd2c29bd3b8e21ab9d871f82346cb71020e3d84bae73e","impliedFormat":1},{"version":"3e70a7e67c2cb16f8cd49097360c0309fe9d1e3210ff9222e9dac1f8df9d4fb6","impliedFormat":1},{"version":"ab68d2a3e3e8767c3fba8f80de099a1cfc18c0de79e42cb02ae66e22dfe14a66","impliedFormat":1},{"version":"d96cc6598148bf1a98fb2e8dcf01c63a4b3558bdaec6ef35e087fd0562eb40ec","impliedFormat":1},{"version":"5ab630d466ac55baa6d32820378098404fc18ba9da6f7bc5df30c5dbb1cffae8","affectsGlobalScope":true,"impliedFormat":1}],"root":[233],"options":{"composite":true,"declaration":true,"declarationMap":true,"downlevelIteration":true,"emitDeclarationOnly":true,"esModuleInterop":true,"experimentalDecorators":true,"importHelpers":true,"jsx":4,"module":100,"noEmitOnError":false,"noImplicitAny":true,"noImplicitThis":true,"noUnusedLocals":true,"noUnusedParameters":true,"outDir":"./ts","rootDir":"../src","skipLibCheck":true,"sourceMap":true,"strictNullChecks":true,"stripInternal":true,"target":8},"fileIdsList":[[237],[187],[239,242],[60],[96],[97,102,131],[98,109,110,117,128,139],[98,99,109,117],[100,140],[101,102,110,118],[102,128,136],[103,105,109,117],[96,104],[105,106],[109],[107,109],[96,109],[109,110,111,128,139],[109,110,111,124,128,131],[94,97,144],[105,109,112,117,128,139],[109,110,112,113,117,128,136,139],[112,114,128,136,139],[60,61,95,96,97,98,99,100,101,102,103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122,123,124,125,126,127,128,129,130,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,146],[109,115],[116,139,144],[105,109,117,128],[118],[119],[96,120],[121,138,144],[122],[123],[109,124,125],[124,126,140,142],[97,109,128,129,130,131],[97,128,130],[128,129],[131],[132],[96,128],[109,134,135],[134,135],[102,117,128,136],[137],[117,138],[97,112,123,139],[102,140],[128,141],[116,142],[143],[97,102,109,111,120,128,139,142,144],[128,145],[54,55,56,57],[58],[235,241],[239],[236,240],[105,109,117,128,136,147,148],[238],[71,75,139],[71,128,139],[66],[68,71,136,139],[117,136],[147],[66,147],[68,71,117,139],[63,64,67,70,97,109,128,139],[63,69],[67,71,97,131,139,147],[97,147],[87,97,147],[65,66,147],[71],[65,66,67,68,69,70,71,72,73,75,76,77,78,79,80,81,82,83,84,85,86,88,89,90,91,92,93],[71,78,79],[69,71,79,80],[70],[63,66,71],[71,75,79,80],[75],[69,71,74,139],[63,68,69,71,75,78],[97,128],[66,71,87,97,144,147],[179,180],[181],[178,179],[178,180,182,183,185],[183],[184],[178],[170,172,173,174,175,176],[167,171],[167,172],[172],[167],[167,168],[169,177],[178,190,191],[190],[53,59,149,228,232],[229],[229,230,231],[229,230],[228],[162,165],[162,211],[151,162,207,208,209,210,212],[154,158,160,162],[160,162],[153],[154,158,210],[150,151,152,161,166],[161,162],[152,160,166],[152,160,162,186,205],[152,160,162,186,203,205],[152,160,186,202],[160,205],[162,205],[152,160,162,192,205],[152,158,160,186,188,189,193,194,203,204],[162,228],[150,152,159,161,162,165,166,205,206,211,213,215,218,220,221,222,223,224,225,226,227],[162,163,164],[152,162],[160],[159,162],[159,160,162,214],[151,154,159],[154,158],[154,158,162,195,218],[162,216,219,228],[217],[162,221],[160,217,218],[195,196,197],[195],[158],[153,155,156,157],[158,198,201],[199,200],[199],[153,195,199],[228,232]],"referencedMap":[[238,1],[188,2],[243,3],[60,4],[61,4],[96,5],[97,6],[98,7],[99,8],[100,9],[101,10],[102,11],[103,12],[104,13],[105,14],[106,14],[108,15],[107,16],[109,17],[110,18],[111,19],[95,20],[112,21],[113,22],[114,23],[147,24],[115,25],[116,26],[117,27],[118,28],[119,29],[120,30],[121,31],[122,32],[123,33],[124,34],[125,34],[126,35],[128,36],[130,37],[129,38],[131,39],[132,40],[133,41],[134,42],[135,43],[136,44],[137,45],[138,46],[139,47],[140,48],[141,49],[142,50],[143,51],[144,52],[145,53],[58,54],[59,55],[242,56],[240,57],[241,58],[149,59],[239,60],[78,61],[85,62],[77,61],[92,63],[69,64],[68,65],[91,66],[86,67],[89,68],[71,69],[70,70],[66,71],[65,72],[88,73],[67,74],[72,75],[76,75],[94,76],[93,75],[80,77],[81,78],[83,79],[79,80],[82,81],[87,66],[74,82],[75,83],[84,84],[64,85],[90,86],[181,87],[182,88],[180,89],[186,90],[184,91],[185,92],[183,89],[179,93],[177,94],[172,95],[176,96],[173,97],[168,98],[175,98],[169,99],[167,66],[178,100],[192,101],[191,102],[190,93],[233,103],[230,104],[232,105],[231,106],[229,107],[166,108],[212,109],[213,110],[207,111],[210,112],[154,113],[211,114],[162,115],[223,116],[161,117],[189,118],[204,119],[203,120],[194,121],[206,122],[193,123],[205,124],[226,113],[224,125],[225,125],[228,126],[165,127],[163,128],[227,129],[214,130],[215,131],[160,132],[159,133],[219,134],[220,135],[218,136],[222,137],[221,138],[198,139],[197,140],[155,141],[156,113],[158,142],[202,143],[201,144],[200,145],[217,146]],"exportedModulesMap":[[238,1],[188,2],[243,3],[60,4],[61,4],[96,5],[97,6],[98,7],[99,8],[100,9],[101,10],[102,11],[103,12],[104,13],[105,14],[106,14],[108,15],[107,16],[109,17],[110,18],[111,19],[95,20],[112,21],[113,22],[114,23],[147,24],[115,25],[116,26],[117,27],[118,28],[119,29],[120,30],[121,31],[122,32],[123,33],[124,34],[125,34],[126,35],[128,36],[130,37],[129,38],[131,39],[132,40],[133,41],[134,42],[135,43],[136,44],[137,45],[138,46],[139,47],[140,48],[141,49],[142,50],[143,51],[144,52],[145,53],[58,54],[59,55],[242,56],[240,57],[241,58],[149,59],[239,60],[78,61],[85,62],[77,61],[92,63],[69,64],[68,65],[91,66],[86,67],[89,68],[71,69],[70,70],[66,71],[65,72],[88,73],[67,74],[72,75],[76,75],[94,76],[93,75],[80,77],[81,78],[83,79],[79,80],[82,81],[87,66],[74,82],[75,83],[84,84],[64,85],[90,86],[181,87],[182,88],[180,89],[186,90],[184,91],[185,92],[183,89],[179,93],[177,94],[172,95],[176,96],[173,97],[168,98],[175,98],[169,99],[167,66],[178,100],[192,101],[191,102],[190,93],[233,147],[230,104],[232,105],[231,106],[229,107],[166,108],[212,109],[213,110],[207,111],[210,112],[154,113],[211,114],[162,115],[223,116],[161,117],[189,118],[204,119],[203,120],[194,121],[206,122],[193,123],[205,124],[226,113],[224,125],[225,125],[228,126],[165,127],[163,128],[227,129],[214,130],[215,131],[160,132],[159,133],[219,134],[220,135],[218,136],[222,137],[221,138],[198,139],[197,140],[155,141],[156,113],[158,142],[202,143],[201,144],[200,145],[217,146]],"semanticDiagnosticsPerFile":[234,235,238,188,187,237,243,60,61,96,97,98,99,100,101,102,103,104,105,106,108,107,109,110,111,95,146,112,113,114,147,115,116,117,118,119,120,121,122,123,124,125,126,127,128,130,129,131,132,133,134,135,136,137,138,139,140,141,142,143,144,145,56,54,58,59,57,148,62,236,55,242,240,241,149,239,53,51,52,9,10,12,11,2,13,14,15,16,17,18,19,20,3,21,4,22,26,23,24,25,27,28,29,5,30,31,32,33,6,37,34,35,36,38,7,39,44,45,40,41,42,43,8,49,46,47,48,1,50,78,85,77,92,69,68,91,86,89,71,70,66,65,88,67,72,73,76,63,94,93,80,81,83,79,82,87,74,75,84,64,90,181,182,180,186,184,185,183,179,174,177,171,172,176,173,168,175,169,167,170,178,192,191,190,233,230,232,231,229,166,212,213,208,207,209,210,154,151,211,162,223,161,189,204,203,194,206,193,205,226,224,225,228,165,163,164,227,214,215,160,159,152,219,220,216,218,222,221,150,196,198,195,197,155,156,158,153,157,202,201,200,199,217],"latestChangedDtsFile":"./ts/mongodb.d.ts"},"version":"5.4.5"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@shopify/shopify-app-session-storage-mongodb",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.5",
|
|
4
4
|
"description": "Shopify App Session Storage for MongoDB",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -9,12 +9,23 @@
|
|
|
9
9
|
"bugs": {
|
|
10
10
|
"url": "https://github.com/Shopify/shopify-app-js/issues"
|
|
11
11
|
},
|
|
12
|
-
"homepage": "https://github.com/Shopify/shopify-app-js/tree/main/packages/shopify-app-session-storage-mongodb",
|
|
12
|
+
"homepage": "https://github.com/Shopify/shopify-app-js/tree/main/packages/apps/session-storage/shopify-app-session-storage-mongodb",
|
|
13
13
|
"author": "Shopify Inc.",
|
|
14
14
|
"license": "MIT",
|
|
15
|
-
"main": "./
|
|
16
|
-
"
|
|
17
|
-
"
|
|
15
|
+
"main": "./dist/cjs/mongodb.js",
|
|
16
|
+
"module": "./dist/esm/mongodb.mjs",
|
|
17
|
+
"types": "./dist/ts/mongodb.d.ts",
|
|
18
|
+
"scripts": {
|
|
19
|
+
"lint": "eslint . --ext .js,.ts",
|
|
20
|
+
"build": "yarn run rollup && yarn tsc -p ./tsconfig.build.json",
|
|
21
|
+
"test": "jest",
|
|
22
|
+
"test:ci": "yarn test",
|
|
23
|
+
"rollup": "rollup -c rollup.config.js --bundleConfigAsCjs",
|
|
24
|
+
"clean": "rimraf .rollup.cache dist",
|
|
25
|
+
"changeset": "changeset",
|
|
26
|
+
"version": "changeset version",
|
|
27
|
+
"release": "yarn build && changeset publish"
|
|
28
|
+
},
|
|
18
29
|
"publishConfig": {
|
|
19
30
|
"access": "public"
|
|
20
31
|
},
|
|
@@ -34,15 +45,14 @@
|
|
|
34
45
|
"mongodb": "^6.3.0"
|
|
35
46
|
},
|
|
36
47
|
"peerDependencies": {
|
|
37
|
-
"@shopify/shopify-api": "^9.7.
|
|
38
|
-
"@shopify/shopify-app-session-storage": "^2.1.
|
|
48
|
+
"@shopify/shopify-api": "^9.7.2 || ^10.0.0",
|
|
49
|
+
"@shopify/shopify-app-session-storage": "^2.1.4"
|
|
39
50
|
},
|
|
40
51
|
"devDependencies": {
|
|
41
|
-
"@shopify/shopify-app-session-storage-test-utils": "^2.0.
|
|
52
|
+
"@shopify/shopify-app-session-storage-test-utils": "^2.0.5"
|
|
42
53
|
},
|
|
43
54
|
"files": [
|
|
44
|
-
"
|
|
45
|
-
"!bundle/*",
|
|
55
|
+
"dist/*",
|
|
46
56
|
"!tsconfig.tsbuildinfo",
|
|
47
57
|
"!node_modules"
|
|
48
58
|
]
|
package/build/cjs/mongodb.js
DELETED
|
@@ -1,117 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
|
-
|
|
5
|
-
var mongodb = require('mongodb');
|
|
6
|
-
var shopifyApi = require('@shopify/shopify-api');
|
|
7
|
-
|
|
8
|
-
function _interopNamespace(e) {
|
|
9
|
-
if (e && e.__esModule) return e;
|
|
10
|
-
var n = Object.create(null);
|
|
11
|
-
if (e) {
|
|
12
|
-
Object.keys(e).forEach(function (k) {
|
|
13
|
-
if (k !== 'default') {
|
|
14
|
-
var d = Object.getOwnPropertyDescriptor(e, k);
|
|
15
|
-
Object.defineProperty(n, k, d.get ? d : {
|
|
16
|
-
enumerable: true,
|
|
17
|
-
get: function () { return e[k]; }
|
|
18
|
-
});
|
|
19
|
-
}
|
|
20
|
-
});
|
|
21
|
-
}
|
|
22
|
-
n["default"] = e;
|
|
23
|
-
return Object.freeze(n);
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
var mongodb__namespace = /*#__PURE__*/_interopNamespace(mongodb);
|
|
27
|
-
|
|
28
|
-
const defaultMongoDBSessionStorageOptions = {
|
|
29
|
-
sessionCollectionName: 'shopify_sessions'
|
|
30
|
-
};
|
|
31
|
-
class MongoDBSessionStorage {
|
|
32
|
-
static withCredentials(host, dbName, username, password, opts) {
|
|
33
|
-
return new MongoDBSessionStorage(new URL(`mongodb://${encodeURIComponent(username)}:${encodeURIComponent(password)}@${host}/`), dbName, opts);
|
|
34
|
-
}
|
|
35
|
-
constructor(dbUrl, dbName, opts = {}) {
|
|
36
|
-
this.dbUrl = dbUrl;
|
|
37
|
-
this.dbName = dbName;
|
|
38
|
-
this.ready = void 0;
|
|
39
|
-
this.options = void 0;
|
|
40
|
-
// `mongodb` has no types for `MongoClient`???!
|
|
41
|
-
this.client = void 0;
|
|
42
|
-
if (typeof this.dbUrl === 'string') {
|
|
43
|
-
this.dbUrl = new URL(this.dbUrl);
|
|
44
|
-
}
|
|
45
|
-
this.options = {
|
|
46
|
-
...defaultMongoDBSessionStorageOptions,
|
|
47
|
-
...opts
|
|
48
|
-
};
|
|
49
|
-
this.ready = this.init();
|
|
50
|
-
}
|
|
51
|
-
async storeSession(session) {
|
|
52
|
-
await this.ready;
|
|
53
|
-
await this.collection.findOneAndReplace({
|
|
54
|
-
id: session.id
|
|
55
|
-
}, session.toObject(), {
|
|
56
|
-
upsert: true
|
|
57
|
-
});
|
|
58
|
-
return true;
|
|
59
|
-
}
|
|
60
|
-
async loadSession(id) {
|
|
61
|
-
await this.ready;
|
|
62
|
-
const result = await this.collection.findOne({
|
|
63
|
-
id
|
|
64
|
-
});
|
|
65
|
-
return result ? new shopifyApi.Session(result) : undefined;
|
|
66
|
-
}
|
|
67
|
-
async deleteSession(id) {
|
|
68
|
-
await this.ready;
|
|
69
|
-
await this.collection.deleteOne({
|
|
70
|
-
id
|
|
71
|
-
});
|
|
72
|
-
return true;
|
|
73
|
-
}
|
|
74
|
-
async deleteSessions(ids) {
|
|
75
|
-
await this.ready;
|
|
76
|
-
await this.collection.deleteMany({
|
|
77
|
-
id: {
|
|
78
|
-
$in: ids
|
|
79
|
-
}
|
|
80
|
-
});
|
|
81
|
-
return true;
|
|
82
|
-
}
|
|
83
|
-
async findSessionsByShop(shop) {
|
|
84
|
-
await this.ready;
|
|
85
|
-
const rawResults = await this.collection.find({
|
|
86
|
-
shop
|
|
87
|
-
}).toArray();
|
|
88
|
-
if (!rawResults || (rawResults === null || rawResults === void 0 ? void 0 : rawResults.length) === 0) return [];
|
|
89
|
-
return rawResults.map(rawResult => new shopifyApi.Session(rawResult));
|
|
90
|
-
}
|
|
91
|
-
async disconnect() {
|
|
92
|
-
await this.client.close();
|
|
93
|
-
}
|
|
94
|
-
get collection() {
|
|
95
|
-
return this.client.db(this.dbName).collection(this.options.sessionCollectionName);
|
|
96
|
-
}
|
|
97
|
-
async init() {
|
|
98
|
-
this.client = new mongodb__namespace.MongoClient(this.dbUrl.toString());
|
|
99
|
-
await this.client.connect();
|
|
100
|
-
await this.client.db().command({
|
|
101
|
-
ping: 1
|
|
102
|
-
});
|
|
103
|
-
await this.createCollection();
|
|
104
|
-
}
|
|
105
|
-
async hasSessionCollection() {
|
|
106
|
-
const collections = await this.client.db().collections();
|
|
107
|
-
return collections.map(collection => collection.collectionName).includes(this.options.sessionCollectionName);
|
|
108
|
-
}
|
|
109
|
-
async createCollection() {
|
|
110
|
-
const hasSessionCollection = await this.hasSessionCollection();
|
|
111
|
-
if (!hasSessionCollection) {
|
|
112
|
-
await this.client.db().collection(this.options.sessionCollectionName);
|
|
113
|
-
}
|
|
114
|
-
}
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
exports.MongoDBSessionStorage = MongoDBSessionStorage;
|
package/build/ts/mongodb.js
DELETED
|
@@ -1,182 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.MongoDBSessionStorage = void 0;
|
|
4
|
-
var tslib_1 = require("tslib");
|
|
5
|
-
var mongodb = tslib_1.__importStar(require("mongodb"));
|
|
6
|
-
var shopify_api_1 = require("@shopify/shopify-api");
|
|
7
|
-
var defaultMongoDBSessionStorageOptions = {
|
|
8
|
-
sessionCollectionName: 'shopify_sessions',
|
|
9
|
-
};
|
|
10
|
-
var MongoDBSessionStorage = /** @class */ (function () {
|
|
11
|
-
function MongoDBSessionStorage(dbUrl, dbName, opts) {
|
|
12
|
-
if (opts === void 0) { opts = {}; }
|
|
13
|
-
this.dbUrl = dbUrl;
|
|
14
|
-
this.dbName = dbName;
|
|
15
|
-
if (typeof this.dbUrl === 'string') {
|
|
16
|
-
this.dbUrl = new URL(this.dbUrl);
|
|
17
|
-
}
|
|
18
|
-
this.options = tslib_1.__assign(tslib_1.__assign({}, defaultMongoDBSessionStorageOptions), opts);
|
|
19
|
-
this.ready = this.init();
|
|
20
|
-
}
|
|
21
|
-
MongoDBSessionStorage.withCredentials = function (host, dbName, username, password, opts) {
|
|
22
|
-
return new MongoDBSessionStorage(new URL("mongodb://".concat(encodeURIComponent(username), ":").concat(encodeURIComponent(password), "@").concat(host, "/")), dbName, opts);
|
|
23
|
-
};
|
|
24
|
-
MongoDBSessionStorage.prototype.storeSession = function (session) {
|
|
25
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
26
|
-
return tslib_1.__generator(this, function (_a) {
|
|
27
|
-
switch (_a.label) {
|
|
28
|
-
case 0: return [4 /*yield*/, this.ready];
|
|
29
|
-
case 1:
|
|
30
|
-
_a.sent();
|
|
31
|
-
return [4 /*yield*/, this.collection.findOneAndReplace({ id: session.id }, session.toObject(), {
|
|
32
|
-
upsert: true,
|
|
33
|
-
})];
|
|
34
|
-
case 2:
|
|
35
|
-
_a.sent();
|
|
36
|
-
return [2 /*return*/, true];
|
|
37
|
-
}
|
|
38
|
-
});
|
|
39
|
-
});
|
|
40
|
-
};
|
|
41
|
-
MongoDBSessionStorage.prototype.loadSession = function (id) {
|
|
42
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
43
|
-
var result;
|
|
44
|
-
return tslib_1.__generator(this, function (_a) {
|
|
45
|
-
switch (_a.label) {
|
|
46
|
-
case 0: return [4 /*yield*/, this.ready];
|
|
47
|
-
case 1:
|
|
48
|
-
_a.sent();
|
|
49
|
-
return [4 /*yield*/, this.collection.findOne({ id: id })];
|
|
50
|
-
case 2:
|
|
51
|
-
result = _a.sent();
|
|
52
|
-
return [2 /*return*/, result ? new shopify_api_1.Session(result) : undefined];
|
|
53
|
-
}
|
|
54
|
-
});
|
|
55
|
-
});
|
|
56
|
-
};
|
|
57
|
-
MongoDBSessionStorage.prototype.deleteSession = function (id) {
|
|
58
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
59
|
-
return tslib_1.__generator(this, function (_a) {
|
|
60
|
-
switch (_a.label) {
|
|
61
|
-
case 0: return [4 /*yield*/, this.ready];
|
|
62
|
-
case 1:
|
|
63
|
-
_a.sent();
|
|
64
|
-
return [4 /*yield*/, this.collection.deleteOne({ id: id })];
|
|
65
|
-
case 2:
|
|
66
|
-
_a.sent();
|
|
67
|
-
return [2 /*return*/, true];
|
|
68
|
-
}
|
|
69
|
-
});
|
|
70
|
-
});
|
|
71
|
-
};
|
|
72
|
-
MongoDBSessionStorage.prototype.deleteSessions = function (ids) {
|
|
73
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
74
|
-
return tslib_1.__generator(this, function (_a) {
|
|
75
|
-
switch (_a.label) {
|
|
76
|
-
case 0: return [4 /*yield*/, this.ready];
|
|
77
|
-
case 1:
|
|
78
|
-
_a.sent();
|
|
79
|
-
return [4 /*yield*/, this.collection.deleteMany({ id: { $in: ids } })];
|
|
80
|
-
case 2:
|
|
81
|
-
_a.sent();
|
|
82
|
-
return [2 /*return*/, true];
|
|
83
|
-
}
|
|
84
|
-
});
|
|
85
|
-
});
|
|
86
|
-
};
|
|
87
|
-
MongoDBSessionStorage.prototype.findSessionsByShop = function (shop) {
|
|
88
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
89
|
-
var rawResults;
|
|
90
|
-
return tslib_1.__generator(this, function (_a) {
|
|
91
|
-
switch (_a.label) {
|
|
92
|
-
case 0: return [4 /*yield*/, this.ready];
|
|
93
|
-
case 1:
|
|
94
|
-
_a.sent();
|
|
95
|
-
return [4 /*yield*/, this.collection.find({ shop: shop }).toArray()];
|
|
96
|
-
case 2:
|
|
97
|
-
rawResults = _a.sent();
|
|
98
|
-
if (!rawResults || (rawResults === null || rawResults === void 0 ? void 0 : rawResults.length) === 0)
|
|
99
|
-
return [2 /*return*/, []];
|
|
100
|
-
return [2 /*return*/, rawResults.map(function (rawResult) { return new shopify_api_1.Session(rawResult); })];
|
|
101
|
-
}
|
|
102
|
-
});
|
|
103
|
-
});
|
|
104
|
-
};
|
|
105
|
-
MongoDBSessionStorage.prototype.disconnect = function () {
|
|
106
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
107
|
-
return tslib_1.__generator(this, function (_a) {
|
|
108
|
-
switch (_a.label) {
|
|
109
|
-
case 0: return [4 /*yield*/, this.client.close()];
|
|
110
|
-
case 1:
|
|
111
|
-
_a.sent();
|
|
112
|
-
return [2 /*return*/];
|
|
113
|
-
}
|
|
114
|
-
});
|
|
115
|
-
});
|
|
116
|
-
};
|
|
117
|
-
Object.defineProperty(MongoDBSessionStorage.prototype, "collection", {
|
|
118
|
-
get: function () {
|
|
119
|
-
return this.client
|
|
120
|
-
.db(this.dbName)
|
|
121
|
-
.collection(this.options.sessionCollectionName);
|
|
122
|
-
},
|
|
123
|
-
enumerable: false,
|
|
124
|
-
configurable: true
|
|
125
|
-
});
|
|
126
|
-
MongoDBSessionStorage.prototype.init = function () {
|
|
127
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
128
|
-
return tslib_1.__generator(this, function (_a) {
|
|
129
|
-
switch (_a.label) {
|
|
130
|
-
case 0:
|
|
131
|
-
this.client = new mongodb.MongoClient(this.dbUrl.toString());
|
|
132
|
-
return [4 /*yield*/, this.client.connect()];
|
|
133
|
-
case 1:
|
|
134
|
-
_a.sent();
|
|
135
|
-
return [4 /*yield*/, this.client.db().command({ ping: 1 })];
|
|
136
|
-
case 2:
|
|
137
|
-
_a.sent();
|
|
138
|
-
return [4 /*yield*/, this.createCollection()];
|
|
139
|
-
case 3:
|
|
140
|
-
_a.sent();
|
|
141
|
-
return [2 /*return*/];
|
|
142
|
-
}
|
|
143
|
-
});
|
|
144
|
-
});
|
|
145
|
-
};
|
|
146
|
-
MongoDBSessionStorage.prototype.hasSessionCollection = function () {
|
|
147
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
148
|
-
var collections;
|
|
149
|
-
return tslib_1.__generator(this, function (_a) {
|
|
150
|
-
switch (_a.label) {
|
|
151
|
-
case 0: return [4 /*yield*/, this.client.db().collections()];
|
|
152
|
-
case 1:
|
|
153
|
-
collections = _a.sent();
|
|
154
|
-
return [2 /*return*/, collections
|
|
155
|
-
.map(function (collection) { return collection.collectionName; })
|
|
156
|
-
.includes(this.options.sessionCollectionName)];
|
|
157
|
-
}
|
|
158
|
-
});
|
|
159
|
-
});
|
|
160
|
-
};
|
|
161
|
-
MongoDBSessionStorage.prototype.createCollection = function () {
|
|
162
|
-
return tslib_1.__awaiter(this, void 0, void 0, function () {
|
|
163
|
-
var hasSessionCollection;
|
|
164
|
-
return tslib_1.__generator(this, function (_a) {
|
|
165
|
-
switch (_a.label) {
|
|
166
|
-
case 0: return [4 /*yield*/, this.hasSessionCollection()];
|
|
167
|
-
case 1:
|
|
168
|
-
hasSessionCollection = _a.sent();
|
|
169
|
-
if (!!hasSessionCollection) return [3 /*break*/, 3];
|
|
170
|
-
return [4 /*yield*/, this.client.db().collection(this.options.sessionCollectionName)];
|
|
171
|
-
case 2:
|
|
172
|
-
_a.sent();
|
|
173
|
-
_a.label = 3;
|
|
174
|
-
case 3: return [2 /*return*/];
|
|
175
|
-
}
|
|
176
|
-
});
|
|
177
|
-
});
|
|
178
|
-
};
|
|
179
|
-
return MongoDBSessionStorage;
|
|
180
|
-
}());
|
|
181
|
-
exports.MongoDBSessionStorage = MongoDBSessionStorage;
|
|
182
|
-
//# sourceMappingURL=mongodb.js.map
|
package/build/ts/mongodb.js.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mongodb.js","sourceRoot":"","sources":["../../src/mongodb.ts"],"names":[],"mappings":";;;;AAAA,uDAAmC;AACnC,oDAA6C;AAM7C,IAAM,mCAAmC,GAAiC;IACxE,qBAAqB,EAAE,kBAAkB;CAC1C,CAAC;AAEF;IAwBE,+BACU,KAAU,EACV,MAAc,EACtB,IAAgD;QAAhD,qBAA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