@payloadcms/db-postgres 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"traverseFields.d.ts","sourceRoot":"","sources":["../../src/find/traverseFields.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAK1C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAG/C,KAAK,iBAAiB,GAAG;IACvB,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,OAAO,EAAE,eAAe,CAAA;IACxB,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACpC,gBAAgB,EAAE,MAAM,CAAA;IACxB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;IACZ,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,iBAAiB,EAAE,MAAM,CAAA;CAC1B,CAAA;AAED,eAAO,MAAM,cAAc,gHAUxB,iBAAiB,
|
1
|
+
{"version":3,"file":"traverseFields.d.ts","sourceRoot":"","sources":["../../src/find/traverseFields.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,eAAe,CAAA;AAK1C,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAG/C,KAAK,iBAAiB,GAAG;IACvB,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACjC,OAAO,EAAE,eAAe,CAAA;IACxB,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACpC,gBAAgB,EAAE,MAAM,CAAA;IACxB,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,IAAI,EAAE,MAAM,CAAA;IACZ,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAA;IACrC,iBAAiB,EAAE,MAAM,CAAA;CAC1B,CAAA;AAED,eAAO,MAAM,cAAc,gHAUxB,iBAAiB,4BA+InB,CAAA"}
|
@@ -107,13 +107,14 @@ const traverseFields = ({ _locales, adapter, currentArgs, currentTableName, dept
|
|
107
107
|
],
|
108
108
|
with: {}
|
109
109
|
};
|
110
|
-
|
110
|
+
const tableName = `${topLevelTableName}_blocks_${(0, _tosnakecase.default)(block.slug)}`;
|
111
|
+
if (adapter.tables[`${tableName}_locales`]) withBlock.with._locales = _locales;
|
111
112
|
topLevelArgs.with[blockKey] = withBlock;
|
112
113
|
traverseFields({
|
113
114
|
_locales,
|
114
115
|
adapter,
|
115
116
|
currentArgs: withBlock,
|
116
|
-
currentTableName,
|
117
|
+
currentTableName: tableName,
|
117
118
|
depth,
|
118
119
|
fields: block.fields,
|
119
120
|
path: '',
|
@@ -146,4 +147,4 @@ const traverseFields = ({ _locales, adapter, currentArgs, currentTableName, dept
|
|
146
147
|
return topLevelArgs;
|
147
148
|
};
|
148
149
|
|
149
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9maW5kL3RyYXZlcnNlRmllbGRzLnRzIl0sInNvdXJjZXNDb250ZW50IjpbIi8qIGVzbGludC1kaXNhYmxlIG5vLXBhcmFtLXJlYXNzaWduICovXG5pbXBvcnQgdHlwZSB7IEZpZWxkIH0gZnJvbSAncGF5bG9hZC90eXBlcydcblxuaW1wb3J0IHsgZmllbGRBZmZlY3RzRGF0YSwgdGFiSGFzTmFtZSB9IGZyb20gJ3BheWxvYWQvdHlwZXMnXG5pbXBvcnQgdG9TbmFrZUNhc2UgZnJvbSAndG8tc25ha2UtY2FzZSdcblxuaW1wb3J0IHR5cGUgeyBQb3N0Z3Jlc0FkYXB0ZXIgfSBmcm9tICcuLi90eXBlcydcbmltcG9ydCB0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xuICAgICAgICAgIGRlcHRoLFxuICAgICAgICAgIGZpZWxkczogdGFiLmZpZWxkcyxcbiAgICAgICAgICBwYXRoOiB0YWJQYXRoLFxuICAgICAgICAgIHRvcExldmVsQXJncyxcbiAgICAgICAgICB0b3BMZXZlbFRhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH0pXG5cbiAgICAgIHJldHVyblxuICAgIH1cblxuICAgIGlmIChmaWVsZEFmZmVjdHNEYXRhKGZpZWxkKSkge1xuICAgICAgc3dpdGNoIChmaWVsZC50eXBlKSB7XG4gICAgICAgIGNhc2UgJ2FycmF5Jzoge1xuICAgICAgICAgIGNvbnN0IHdpdGhBcnJheTogUmVzdWx0ID0ge1xuICAgICAgICAgICAgY29sdW1uczoge1xuICAgICAgICAgICAgICBfcGFyZW50SUQ6IGZhbHNlLFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIG9yZGVyQnk6ICh7IF9vcmRlciB9LCB7IGFzYyB9KSA9PiBbYXNjKF9vcmRlcildLFxuICAgICAgICAgICAgd2l0aDoge30sXG4gICAgICAgICAgfVxuXG4gICAgICAgICAgY29uc3QgYXJyYXlUYWJsZU5hbWUgPSBgJHtjdXJyZW50VGFibGVOYW1lfV8ke3RvU25ha2VDYXNlKGZpZWxkLm5hbWUpfWBcblxuICAgICAgICAgIGlmIChhZGFwdGVyLnRhYmxlc1tgJHthcnJheVRhYmxlTmFtZX1fbG9jYWxlc2BdKSB3aXRoQXJyYXkud2l0aC5fbG9jYWxlcyA9IF9sb2NhbGVzXG4gICAgICAgICAgY3VycmVudEFyZ3Mud2l0aFtgJHtwYXRofSR7ZmllbGQubmFtZX1gXSA9IHdpdGhBcnJheVxuXG4gICAgICAgICAgdHJhdmVyc2VGaWVsZHMoe1xuICAgICAgICAgICAgX2xvY2FsZXMsXG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgY3VycmVudEFyZ3M6IHdpdGhBcnJheSxcbiAgICAgICAgICAgIGN1cnJlbnRUYWJsZU5hbWU6IGFycmF5VGFibGVOYW1lLFxuICAgICAgICAgICAgZGVwdGgsXG4gICAgICAgICAgICBmaWVsZHM6IGZpZWxkLmZpZWxkcyxcbiAgICAgICAgICAgIHBhdGg6ICcnLFxuICAgICAgICAgICAgdG9wTGV2ZWxBcmdzLFxuICAgICAgICAgICAgdG9wTGV2ZWxUYWJsZU5hbWUsXG4gICAgICAgICAgfSlcblxuICAgICAgICAgIGJyZWFrXG4gICAgICAgIH1cblxuICAgICAgICBjYXNlICdzZWxlY3QnOiB7XG4gICAgICAgICAgaWYgKGZpZWxkLmhhc01hbnkpIHtcbiAgICAgICAgICAgIGNvbnN0IHdpdGhTZWxlY3Q6IFJlc3VsdCA9IHtcbiAgICAgICAgICAgICAgY29sdW1uczoge1xuICAgICAgICAgICAgICAgIGlkOiBmYWxzZSxcbiAgICAgICAgICAgICAgICBvcmRlcjogZmFsc2UsXG4gICAgICAgICAgICAgICAgcGFyZW50OiBmYWxzZSxcbiAgICAgICAgICAgICAgfSxcbiAgICAgICAgICAgICAgb3JkZXJCeTogKHsgb3JkZXIgfSwgeyBhc2MgfSkgPT4gW2FzYyhvcmRlcildLFxuICAgICAgICAgICAgfVxuXG4gICAgICAgICAgICBjdXJyZW50QXJncy53aXRoW2Ake3BhdGh9JHtmaWVsZC5uYW1lfWBdID0gd2l0aFNlbGVjdFxuICAgICAgICAgIH1cblxuICAgICAgICAgIGJyZWFrXG4gICAgICAgIH1cblxuICAgICAgICBjYXNlICdibG9ja3MnOlxuICAgICAgICAgIGZpZWxkLmJsb2Nrcy5mb3JFYWNoKChibG9jaykgPT4ge1xuICAgICAgICAgICAgY29uc3QgYmxvY2tLZXkgPSBgX2Jsb2Nrc18ke2Jsb2NrLnNsdWd9YFxuXG4gICAgICAgICAgICBpZiAoIXRvcExldmVsQXJnc1tibG9ja0tleV0pIHtcbiAgICAgICAgICAgICAgY29uc3Qgd2l0aEJsb2NrOiBSZXN1bHQgPSB7XG4gICAgICAgICAgICAgICAgY29sdW1uczoge1xuICAgICAgICAgICAgICAgICAgX3BhcmVudElEOiBmYWxzZSxcbiAgICAgICAgICAgICAgICB9LFxuICAgICAgICAgICAgICAgIG9yZGVyQnk6ICh7IF9vcmRlciB9LCB7IGFzYyB9KSA9PiBbYXNjKF9vcmRlcildLFxuICAgICAgICAgICAgICAgIHdpdGg6IHt9LFxuICAgICAgICAgICAgICB9XG5cbiAgICAgICAgICAgICAgY29uc3QgdGFibGVOYW1lID0gYCR7dG9wTGV2ZWxUYWJsZU5hbWV9X2Jsb2Nrc18ke3RvU25ha2VDYXNlKGJsb2NrLnNsdWcpfWBcblxuICAgICAgICAgICAgICBpZiAoYWRhcHRlci50YWJsZXNbYCR7dGFibGVOYW1lfV9sb2NhbGVzYF0pIHdpdGhCbG9jay53aXRoLl9sb2NhbGVzID0gX2xvY2FsZXNcbiAgICAgICAgICAgICAgdG9wTGV2ZWxBcmdzLndpdGhbYmxvY2tLZXldID0gd2l0aEJsb2NrXG5cbiAgICAgICAgICAgICAgdHJhdmVyc2VGaWVsZHMoe1xuICAgICAgICAgICAgICAgIF9sb2NhbGVzLFxuICAgICAgICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgICAgICAgY3VycmVudEFyZ3M6IHdpdGhCbG9jayxcbiAgICAgICAgICAgICAgICBjdXJyZW50VGFibGVOYW1lOiB0YWJsZU5hbWUsXG4gICAgICAgICAgICAgICAgZGVwdGgsXG4gICAgICAgICAgICAgICAgZmllbGRzOiBibG9jay5maWVsZHMsXG4gICAgICAgICAgICAgICAgcGF0aDogJycsXG4gICAgICAgICAgICAgICAgdG9wTGV2ZWxBcmdzLFxuICAgICAgICAgICAgICAgIHRvcExldmVsVGFibGVOYW1lLFxuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0pXG5cbiAgICAgICAgICBicmVha1xuXG4gICAgICAgIGNhc2UgJ2dyb3VwJzpcbiAgICAgICAgICB0cmF2ZXJzZUZpZWxkc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7d0JBQ2JDO3dCQUNBQzt3QkFDQUM7d0JBQ0FDO3dCQUNBQzt3QkFDQUMsUUFBUUssTUFBTUwsTUFBTTt3QkFDcEJDLE1BQU0sQ0FBQyxFQUFFQSxLQUFLLEVBQUVJLE1BQU1NLElBQUksQ0FBQyxDQUFDLENBQUM7d0JBQzdCVDt3QkFDQUM7b0JBQ0Y7b0JBRUE7Z0JBRUY7b0JBQVM7d0JBQ1A7b0JBQ0Y7WUFDRjtRQUNGO0lBQ0Y7SUFFQSxPQUFPRDtBQUNUIn0=
|
package/dist/findOne.d.ts.map
CHANGED
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"findOne.d.ts","sourceRoot":"","sources":["../src/findOne.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AACnD,OAAO,KAAK,EAA6C,UAAU,EAAE,MAAM,eAAe,CAAA;AAI1F,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;
|
1
|
+
{"version":3,"file":"findOne.d.ts","sourceRoot":"","sources":["../src/findOne.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,kBAAkB,CAAA;AACnD,OAAO,KAAK,EAA6C,UAAU,EAAE,MAAM,eAAe,CAAA;AAI1F,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAA;AAI9C,wBAAsB,OAAO,CAAC,CAAC,SAAS,UAAU,EAChD,IAAI,EAAE,eAAe,EACrB,EAAE,UAAU,EAAE,MAAM,EAAE,GAA0B,EAAE,KAAK,EAAE,aAAa,EAAE,EAAE,WAAW,GACpF,OAAO,CAAC,CAAC,CAAC,CAiBZ"}
|
package/dist/findOne.js
CHANGED
@@ -9,41 +9,27 @@ Object.defineProperty(exports, "findOne", {
|
|
9
9
|
}
|
10
10
|
});
|
11
11
|
const _tosnakecase = /*#__PURE__*/ _interop_require_default(require("to-snake-case"));
|
12
|
-
const
|
13
|
-
const _buildQuery = /*#__PURE__*/ _interop_require_default(require("./queries/buildQuery"));
|
14
|
-
const _read = require("./transform/read");
|
12
|
+
const _findMany = require("./find/findMany");
|
15
13
|
function _interop_require_default(obj) {
|
16
14
|
return obj && obj.__esModule ? obj : {
|
17
15
|
default: obj
|
18
16
|
};
|
19
17
|
}
|
20
18
|
async function findOne({ collection, locale, req = {}, where: incomingWhere }) {
|
21
|
-
const db = this.sessions[req.transactionID]?.db || this.drizzle;
|
22
19
|
const collectionConfig = this.payload.collections[collection].config;
|
23
|
-
const
|
24
|
-
const { where } = await (0, _buildQuery.default)({
|
20
|
+
const { docs } = await (0, _findMany.findMany)({
|
25
21
|
adapter: this,
|
26
22
|
fields: collectionConfig.fields,
|
23
|
+
limit: 1,
|
27
24
|
locale,
|
28
|
-
|
25
|
+
page: 1,
|
26
|
+
pagination: false,
|
27
|
+
req,
|
28
|
+
sort: undefined,
|
29
|
+
tableName: (0, _tosnakecase.default)(collection),
|
29
30
|
where: incomingWhere
|
30
31
|
});
|
31
|
-
|
32
|
-
adapter: this,
|
33
|
-
depth: 0,
|
34
|
-
fields: collectionConfig.fields,
|
35
|
-
tableName
|
36
|
-
});
|
37
|
-
findManyArgs.where = where;
|
38
|
-
const doc = await db.query[tableName].findFirst(findManyArgs);
|
39
|
-
if (!doc) {
|
40
|
-
return null;
|
41
|
-
}
|
42
|
-
return (0, _read.transform)({
|
43
|
-
config: this.payload.config,
|
44
|
-
data: doc,
|
45
|
-
fields: collectionConfig.fields
|
46
|
-
});
|
32
|
+
return docs?.[0] || null;
|
47
33
|
}
|
48
34
|
|
49
|
-
//# sourceMappingURL=data:application/json;base64,
|
35
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9maW5kT25lLnRzIl0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0eXBlIHsgRmluZE9uZUFyZ3MgfSBmcm9tICdwYXlsb2FkL2RhdGFiYXNlJ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EAAE,qBAAqB,CAAA;IAClC,KAAK,EAAE,eAAe,CAAA;IACtB,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,YAAY,EAAE,MAAM,EAAE,CAAA;IACtB,aAAa,CAAC,EAAE,MAAM,CAAA;IACtB,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAA;IAC3C,SAAS,EAAE,MAAM,CAAA;CAClB,CAAA;AACD;;;;GAIG;AACH,eAAO,MAAM,sBAAsB,mQAehC,IAAI,KAAG,WAoXT,CAAA"}
|
@@ -179,6 +179,7 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
|
|
179
179
|
let newTableName;
|
180
180
|
const hasBlockField = field.blocks.some((block)=>{
|
181
181
|
newTableName = `${tableName}_blocks_${(0, _tosnakecase.default)(block.slug)}`;
|
182
|
+
constraintPath = `${constraintPath}${field.name}.%.`;
|
182
183
|
let result;
|
183
184
|
const blockConstraints = [];
|
184
185
|
const blockSelectFields = {};
|
@@ -186,7 +187,7 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
|
|
186
187
|
result = getTableColumnFromPath({
|
187
188
|
adapter,
|
188
189
|
collectionPath,
|
189
|
-
constraintPath
|
190
|
+
constraintPath,
|
190
191
|
constraints: blockConstraints,
|
191
192
|
fields: block.fields,
|
192
193
|
joinAliases,
|
@@ -221,7 +222,7 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
|
|
221
222
|
} else {
|
222
223
|
joins[newTableName] = (0, _drizzleorm.eq)(adapter.tables[tableName].id, adapter.tables[newTableName]._parentID);
|
223
224
|
}
|
224
|
-
return
|
225
|
+
return true;
|
225
226
|
});
|
226
227
|
if (hasBlockField) {
|
227
228
|
return {
|
@@ -230,7 +231,7 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
|
|
230
231
|
field: blockTableColumn.field,
|
231
232
|
pathSegments: pathSegments.slice(1),
|
232
233
|
rawColumn: blockTableColumn.rawColumn,
|
233
|
-
table:
|
234
|
+
table: blockTableColumn.table
|
234
235
|
};
|
235
236
|
}
|
236
237
|
if (pathSegments[1] === 'blockType') {
|
@@ -349,4 +350,4 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
|
|
349
350
|
throw new _errors.APIError(`Cannot find field for path at ${fieldPath}`);
|
350
351
|
};
|
351
352
|
|
352
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9xdWVyaWVzL2dldFRhYmxlQ29sdW1uRnJvbVBhdGgudHMiXSwic291cmNlc0NvbnRlbnQiOlsiLyogZXNsaW50LWRpc2FibGUgbm8tcGFyYW0tcmVhc3NpZ24gKi9cbmltcG9ydCB0eXBlIHsgU1FMIH0gZnJvbSAnZHJpenpsZS1vcm0nXG5pbXBvcnQgdHlwZSB7IEZpZWxkLCBGaWVsZEFmZmVjdGluZ0RhdGEsIFRhYkFzRmllbGQgfSBmcm9tICdwYXlsb2FkL3R5cGVzJ1xuXG5pbXBvcnQgeyBhbmQsIGVxLCBzcWwgfSBmcm9tICdkcml6emxlLW9ybSdcbmltcG9ydCB7IGFsaWFzIH0gZnJvbSAnZHJpenpsZS1vcm0vcGctY29yZSdcbmltcG9ydCB7IEFQSUVycm9yIH0gZnJvbSAncGF5bG9hZC9lcnJvcnMnXG5pbXBvcnQgeyBmaWVsZEFmZmVjdHNEYXRhLCB0YWJIYXNOYW1lIH0gZnJvbSAncGF5bG9hZC90eXBlcydcbmltcG9ydCB7IGZsYXR0ZW5Ub3BMZXZlbEZpZWxkcyB9IGZyb20gJ3BheWxvYWQvdXRpbGl0aWVzJ1xuaW1wb3J0IHRvU25ha2VDYXNlIGZyb20gJ3RvLXNuYWtlLWNhc2UnXG5pbXBvcnQgeyB2NCBhcyB1dWlkIH0gZnJvbSAndXVpZCdcblxuaW1wb3J0IHR5cGUgeyBHZW5lcmljQ29sdW1uLCBHZW5lcmljV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blxuICAgICAgaWYgKG1hdGNoZWRMb2NhbGUpIHtcbiAgICAgICAgbG9jYWxlID0gbWF0Y2hlZExvY2FsZVxuICAgICAgICBwYXRoU2VnbWVudHMuc3BsaWNlKDEsIDEpXG4gICAgICB9XG4gICAgfVxuXG4gICAgc3dpdGNoIChmaWVsZC50eXBlKSB7XG4gICAgICBjYXNlICd0YWJzJzoge1xuICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICBhbGlhc1RhYmxlLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbHVtblByZWZpeCxcbiAgICAgICAgICBjb25zdHJhaW50UGF0aCxcbiAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICBmaWVsZHM6IGZpZWxkLnRhYnMubWFwKCh0YWIpID0+ICh7XG4gICAgICAgICAgICAuLi50YWIsXG4gICAgICAgICAgICB0eXBlOiAndGFiJyxcbiAgICAgICAgICB9KSksXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuICAgICAgY2FzZSAndGFiJzoge1xuICAgICAgICBpZiAodGFiSGFzTmFtZShmaWVsZCkpIHtcbiAgICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgICBqb2lucyxcbiAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgICAgcm9vdFRhYmxlTmFtZSxcbiAgICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgIH0pXG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGdldFRhYmxlQ29sdW1uRnJvbVBhdGgoe1xuICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICBjb2xsZWN0aW9uUGF0aCxcbiAgICAgICAgICBjb2x1bW5QcmVmaXgsXG4gICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgZmllbGRzOiBmaWVsZC5maWVsZHMsXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICBjYXNlICdncm91cCc6IHtcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2xvY2FsZXNgXG5cbiAgICAgICAgICBqb2luc1t0YWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICAgIGlmIChsb2NhbGUgIT09ICdhbGwnKSB7XG4gICAgICAgICAgICBjb25zdHJhaW50cy5wdXNoKHtcbiAgICAgICAgICAgICAgY29sdW1uTmFtZTogJ19sb2NhbGUnLFxuICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgdmFsdWU6IGxvY2FsZSxcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGFsaWFzVGFibGUsXG4gICAgICAgICAgY29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYXJyYXknOiB7XG4gICAgICAgIG5ld1RhYmxlTmFtZSA9IGAke3RhYmxlTmFtZX1fJHt0b1NuYWtlQ2FzZShmaWVsZC5uYW1lKX1gXG4gICAgICAgIGNvbnN0cmFpbnRQYXRoID0gYCR7Y29uc3RyYWludFBhdGh9JHtmaWVsZC5uYW1lfS4lLmBcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gYW5kKFxuICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fbG9jYWxlLCBsb2NhbGUpLFxuICAgICAgICAgIClcbiAgICAgICAgICBpZiAobG9jYWxlICE9PSAnYWxsJykge1xuICAgICAgICAgICAgY29uc3RyYWludHMucHVzaCh7XG4gICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgdGFibGU6IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0sXG4gICAgICAgICAgICAgIHZhbHVlOiBsb2NhbGUsXG4gICAgICAgICAgICB9KVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYmxvY2tzJzoge1xuICAgICAgICBsZXQgYmxvY2tUYWJsZUNvbHVtbjogVGFibGVDb2x1bW5cbiAgICAgICAgbGV0IG5ld1RhYmxlTmFtZTogc3RyaW5nXG4gICAgICAgIGNvbnN0IGhhc0Jsb2NrRmllbGQgPSBmaWVsZC5ibG9ja3Muc29tZSgoYmxvY2spID0+IHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2Jsb2Nrc18ke3RvU25ha2VDYXNlKGJsb2NrLnNsdWcpfWBcbiAgICAgICAgICBsZXQgcmVzdWx0XG4gICAgICAgICAgY29uc3QgYmxvY2tDb25zdHJhaW50cyA9IFtdXG4gICAgICAgICAgY29uc3QgYmxvY2tTZWxlY3RGaWVsZHMgPSB7fVxuICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICByZXN1bHQgPSBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICAgICAgY29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRQYXRoOiAnJyxcbiAgICAgICAgICAgICAgY29uc3RyYWludHM6IGJsb2NrQ29uc3RyYWludHMsXG4gICAgICAgICAgICAgIGZpZWxkczogYmxvY2suZmllbGRzLFxuICAgICAgICAgICAgICBqb2luQWxpYXNlcyxcbiAgICAgICAgICAgICAgam9pbnMsXG4gICAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgICAgcGF0aFNlZ21lbnRzOiBwYXRoU2VnbWVudHMuc2xpY2UoMSksXG4gICAgICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgICAgIHNlbGVjdEZpZWxkczogYmxvY2tTZWxlY3RGaWVsZHMsXG4gICAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgICAgfSlcbiAgICAgICAgICB9IGNhdGNoIChlcnJvcikge1xuICAgICAgICAgICAgLy8gdGhpcyBpcyBmaW5lLCBub3QgZXZlcnkgYmxvY2sgd2lsbCBoYXZlIHRoZSBmaWVsZFxuICAgICAgICAgIH1cbiAgICAgICAgICBpZiAoIXJlc3VsdCkge1xuICAgICAgICAgICAgcmV0dXJuXG4gICAgICAgICAgfVxuICAgICAgICAgIGJsb2NrVGFibGVDb2x1bW4gPSByZXN1bHRcbiAgICAgICAgICBjb25zdHJhaW50cyA9IGNvbnN0cmFpbnRzLmNvbmNhdChibG9ja0NvbnN0cmFpbnRzKVxuICAgICAgICAgIHNlbGVjdEZpZWxkcyA9IHsgLi4uc2VsZWN0RmllbGRzLCAuLi5ibG9ja1NlbGVjdEZpZWxkcyB9XG4gICAgICAgICAgaWYgKGZpZWxkLmxvY2FsaXplZCAmJiBhZGFwdGVyLnBheWxvYWQuY29uZmlnLmxvY2FsaXphdGlvbikge1xuICAgICAgICAgICAgam9pbnNbbmV3VGFibGVOYW1lXSA9IGFuZChcbiAgICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgICBlcShhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLl9sb2NhbGUsIGxvY2FsZSksXG4gICAgICAgICAgICApXG4gICAgICAgICAgICBpZiAobG9jYWxlKSB7XG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRzLnB1c2goe1xuICAgICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogbG9jYWxlLFxuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW3RhYmxlTmFtZV0uaWQsXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0uX3BhcmVudElELFxuICAgICAgICAgICAgKVxuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gcmVzdWx0XG4gICAgICAgIH0pXG4gICAgICAgIGlmIChoYXNCbG9ja0ZpZWxkKSB7XG4gICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgIGNvbHVtbk5hbWU6IGJsb2NrVGFibGVDb2x1bW4uY29sdW1uTmFtZSxcbiAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgZmllbGQ6IGJsb2NrVGFibGVDb2x1bW4uZmllbGQsXG4gICAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcb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Rpb25zaGlwVGFibGVbYCR7ZmllbGQucmVsYXRpb25Ub31JRGBdKSxcbiAgICAgICAgICAgIHRhYmxlOiBuZXdBbGlhc1RhYmxlLFxuICAgICAgICAgIH0pXG5cbiAgICAgICAgICBpZiAobmV3Q29sbGVjdGlvblBhdGggPT09ICcnKSB7XG4gICAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgICBjb2x1bW5OYW1lOiBgJHtmaWVsZC5yZWxhdGlvblRvfUlEYCxcbiAgICAgICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgICAgIGZpZWxkLFxuICAgICAgICAgICAgICB0YWJsZTogYWxpYXNSZWxhdGlvbnNoaXBUYWJsZSxcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSBpZiAobmV3Q29sbGVjdGlvblBhdGggPT09ICd2YWx1ZScpIHtcbiAgICAgICAgICBjb25zdCB0YWJsZUNvbHVtbnNOYW1lcyA9IGZpZWxkLnJlbGF0aW9uVG8ubWFwKFxuICAgICAgICAgICAgKHJlbGF0aW9uVG8pID0+IGBcIiR7YWxpYXNSZWxhdGlvbnNoaXBUYWJsZU5hbWV9XCIuXCIke3RvU25ha2VDYXNlKHJlbGF0aW9uVG8pfV9pZFwiYCxcbiAgICAgICAgICApXG4gICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgZmllbGQsXG4gICAgICAgICAgICByYXdDb2x1bW46IHNxbC5yYXcoYENPQUxFU0NFKCR7dGFibGVDb2x1bW5zTmFtZXMuam9pbignLCAnKX0pYCksXG4gICAgICAgICAgICB0YWJsZTogYWxpYXNSZWxhdGlvbnNoaXBUYWJsZSxcbiAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSBpZiAobmV3Q29sbGVjdGlvblBhdGggPT09ICdyZWxhdGlvblRvJykge1xuICAgICAgICAgIGNvbnN0IHJlbGF0aW9uVG8gPSBBcnJheS5pc0FycmF5KGZpZWxkLnJlbGF0aW9uVG8pID8gZmllbGQucmVsYXRpb25UbyA6IFtmaWVsZC5yZWxhdGlvblRvXVxuXG4gICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgZmllbGQsXG4gICAgICAgICAgICBnZXROb3ROdWxsQ29sdW1uQnlWYWx1ZTogKHZhbCkgPT4ge1xuICAgICAgICAgICAgICBjb25zdCBtYXRjaGVkUmVsYXRpb24gPSByZWxhdGlvblRvLmZpbmQoKHJlbGF0aW9uKSA9PiByZWxhdGlvbiA9PT0gdmFsKVxuICAgICAgICAgICAgICBpZiAobWF0Y2hlZFJlbGF0aW9uKSByZXR1cm4gYCR7bWF0Y2hlZFJlbGF0aW9ufUlEYFxuICAgICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgdGFibGU6IGFsaWFzUmVsYXRpb25zaGlwVGFibGUsXG4gICAgICAgICAgfVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHRocm93IG5ldyBBUElFcnJvcignTm90IHN1cHBvcnRlZCcpXG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICBhbGlhc1RhYmxlOiBuZXdBbGlhc1RhYmxlLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoOiBuZXdDb2xsZWN0aW9uUGF0aCxcbiAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICBmaWVsZHM6IHJlbGF0aW9uc2hpcEZpZWxkcyxcbiAgICAgICAgICBqb2luQWxpYXNlcyxcbiAgICAgICAgICBqb2lucyxcbiAgICAgICAgICBsb2NhbGUsXG4gICAgICAgICAgcGF0aFNlZ21lbnRzOiBwYXRoU2VnbWVudHMuc2xpY2UoMSksXG4gICAgICAgICAgcm9vdFRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgZGVmYXVsdDoge1xuICAgICAgICBpZiAoZmllbGRBZmZlY3RzRGF0YShmaWVsZCkpIHtcbiAgICAgICAgICBpZiAoZmllbGQubG9jYWxpemVkICYmIGFkYXB0ZXIucGF5bG9hZC5jb25maWcubG9jYWxpemF0aW9uKSB7XG4gICAgICAgICAgICAvLyBJZiBsb2NhbGl6ZWQsIHdlIGdvIHRvIGxvY2FsaXplZCB0YWJsZSBhbmQgc2V0IGFsaWFzVGFibGUgdG8gdW5kZWZpbmVkXG4gICAgICAgICAgICAvLyBzbyBpdCBpcyBub3QgcGlja2VkIHVwIGJlbG93IHRvIGJlIHVzZWQgYXMgdGFyZ2V0VGFibGVcbiAgICAgICAgICAgIG5ld1RhYmxlTmFtZSA9IGAke3RhYmxlTmFtZX1fbG9jYWxlc2BcblxuICAgICAgICAgICAgY29uc3QgcGFyZW50VGFibGUgPSBhbGlhc1RhYmxlIHx8IGFkYXB0ZXIudGFibGVzW3RhYmxlTmFtZV1cblxuICAgICAgICAgICAgam9pbnNbbmV3VGFibGVOYW1lXSA9IGVxKHBhcmVudFRhYmxlLmlkLCBhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLl9wYXJlbnRJRClcblxuICAgICAgICAgICAgYWxpYXNUYWJsZSA9IHVuZGVmaW5lZFxuXG4gICAgICAgICAgICBpZiAobG9jYWxlICE9PSAnYWxsJykge1xuICAgICAgICAgICAgICBjb25zdHJhaW50cy5wdXNoKHtcbiAgICAgICAgICAgICAgICBjb2x1bW5OYW1lOiAnX2xvY2FsZScsXG4gICAgICAgICAgICAgICAgdGFibGU6IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0sXG4gICAgICAgICAgICAgICAgdmFsdWU6IG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9PiBsb2NhbGUgPT09IHBhdGhTZWdtZW50c1sxXSxcbiAgICAgIClcblxuICAgICAgaWYgKG1hdGNoZWRMb2NhbGUpIHtcbiAgICAgICAgbG9jYWxlID0gbWF0Y2hlZExvY2FsZVxuICAgICAgICBwYXRoU2VnbWVudHMuc3BsaWNlKDEsIDEpXG4gICAgICB9XG4gICAgfVxuXG4gICAgc3dpdGNoIChmaWVsZC50eXBlKSB7XG4gICAgICBjYXNlICd0YWJzJzoge1xuICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICBhbGlhc1RhYmxlLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbHVtblByZWZpeCxcbiAgICAgICAgICBjb25zdHJhaW50UGF0aCxcbiAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICBmaWVsZHM6IGZpZWxkLnRhYnMubWFwKCh0YWIpID0+ICh7XG4gICAgICAgICAgICAuLi50YWIsXG4gICAgICAgICAgICB0eXBlOiAndGFiJyxcbiAgICAgICAgICB9KSksXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuICAgICAgY2FzZSAndGFiJzoge1xuICAgICAgICBpZiAodGFiSGFzTmFtZShmaWVsZCkpIHtcbiAgICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgICBqb2lucyxcbiAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgICAgcm9vdFRhYmxlTmFtZSxcbiAgICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgIH0pXG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGdldFRhYmxlQ29sdW1uRnJvbVBhdGgoe1xuICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICBjb2xsZWN0aW9uUGF0aCxcbiAgICAgICAgICBjb2x1bW5QcmVmaXgsXG4gICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgZmllbGRzOiBmaWVsZC5maWVsZHMsXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICBjYXNlICdncm91cCc6IHtcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2xvY2FsZXNgXG5cbiAgICAgICAgICBqb2luc1t0YWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICAgIGlmIChsb2NhbGUgIT09ICdhbGwnKSB7XG4gICAgICAgICAgICBjb25zdHJhaW50cy5wdXNoKHtcbiAgICAgICAgICAgICAgY29sdW1uTmFtZTogJ19sb2NhbGUnLFxuICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgdmFsdWU6IGxvY2FsZSxcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGFsaWFzVGFibGUsXG4gICAgICAgICAgY29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYXJyYXknOiB7XG4gICAgICAgIG5ld1RhYmxlTmFtZSA9IGAke3RhYmxlTmFtZX1fJHt0b1NuYWtlQ2FzZShmaWVsZC5uYW1lKX1gXG4gICAgICAgIGNvbnN0cmFpbnRQYXRoID0gYCR7Y29uc3RyYWludFBhdGh9JHtmaWVsZC5uYW1lfS4lLmBcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gYW5kKFxuICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fbG9jYWxlLCBsb2NhbGUpLFxuICAgICAgICAgIClcbiAgICAgICAgICBpZiAobG9jYWxlICE9PSAnYWxsJykge1xuICAgICAgICAgICAgY29uc3RyYWludHMucHVzaCh7XG4gICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgdGFibGU6IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0sXG4gICAgICAgICAgICAgIHZhbHVlOiBsb2NhbGUsXG4gICAgICAgICAgICB9KVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYmxvY2tzJzoge1xuICAgICAgICBsZXQgYmxvY2tUYWJsZUNvbHVtbjogVGFibGVDb2x1bW5cbiAgICAgICAgbGV0IG5ld1RhYmxlTmFtZTogc3RyaW5nXG4gICAgICAgIGNvbnN0IGhhc0Jsb2NrRmllbGQgPSBmaWVsZC5ibG9ja3Muc29tZSgoYmxvY2spID0+IHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2Jsb2Nrc18ke3RvU25ha2VDYXNlKGJsb2NrLnNsdWcpfWBcbiAgICAgICAgICBjb25zdHJhaW50UGF0aCA9IGAke2NvbnN0cmFpbnRQYXRofSR7ZmllbGQubmFtZX0uJS5gXG4gICAgICAgICAgbGV0IHJlc3VsdFxuICAgICAgICAgIGNvbnN0IGJsb2NrQ29uc3RyYWludHMgPSBbXVxuICAgICAgICAgIGNvbnN0IGJsb2NrU2VsZWN0RmllbGRzID0ge31cbiAgICAgICAgICB0cnkge1xuICAgICAgICAgICAgcmVzdWx0ID0gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgICAgICBjb25zdHJhaW50UGF0aCxcbiAgICAgICAgICAgICAgY29uc3RyYWludHM6IGJsb2NrQ29uc3RyYWludHMsXG4gICAgICAgICAgICAgIGZpZWxkczogYmxvY2suZmllbGRzLFxuICAgICAgICAgICAgICBqb2luQWxpYXNlcyxcbiAgICAgICAgICAgICAgam9pbnMsXG4gICAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgICAgcGF0aFNlZ21lbnRzOiBwYXRoU2VnbWVudHMuc2xpY2UoMSksXG4gICAgICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgICAgIHNlbGVjdEZpZWxkczogYmxvY2tTZWxlY3RGaWVsZHMsXG4gICAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgICAgfSlcbiAgICAgICAgICB9IGNhdGNoIChlcnJvcikge1xuICAgICAgICAgICAgLy8gdGhpcyBpcyBmaW5lLCBub3QgZXZlcnkgYmxvY2sgd2lsbCBoYXZlIHRoZSBmaWVsZFxuICAgICAgICAgIH1cbiAgICAgICAgICBpZiAoIXJlc3VsdCkge1xuICAgICAgICAgICAgcmV0dXJuXG4gICAgICAgICAgfVxuICAgICAgICAgIGJsb2NrVGFibGVDb2x1bW4gPSByZXN1bHRcbiAgICAgICAgICBjb25zdHJhaW50cyA9IGNvbnN0cmFpbnRzLmNvbmNhdChibG9ja0NvbnN0cmFpbnRzKVxuICAgICAgICAgIHNlbGVjdEZpZWxkcyA9IHsgLi4uc2VsZWN0RmllbGRzLCAuLi5ibG9ja1NlbGVjdEZpZWxkcyB9XG4gICAgICAgICAgaWYgKGZpZWxkLmxvY2FsaXplZCAmJiBhZGFwdGVyLnBheWxvYWQuY29uZmlnLmxvY2FsaXphdGlvbikge1xuICAgICAgICAgICAgam9pbnNbbmV3VGFibGVOYW1lXSA9IGFuZChcbiAgICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgICBlcShhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLl9sb2NhbGUsIGxvY2FsZSksXG4gICAgICAgICAgICApXG4gICAgICAgICAgICBpZiAobG9jYWxlKSB7XG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRzLnB1c2goe1xuICAgICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogbG9jYWxlLFxuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW3RhYmxlTmFtZV0uaWQsXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0uX3BhcmVudElELFxuICAgICAgICAgICAgKVxuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gdHJ1ZVxuICAgICAgICB9KVxuICAgICAgICBpZiAoaGFzQmxvY2tGaWVsZCkge1xuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICBjb2x1bW5OYW1lOiBibG9ja1RhYmxlQ29sdW1uLmNvbHVtbk5hbWUsXG4gICAgICAgICAgICBjb25zdHJhaW50cyx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AgICAgICAgIGpvaW5BbGlhc2VzLnB1c2goe1xuICAgICAgICAgICAgY29uZGl0aW9uOiBlcShuZXdBbGlhc1RhYmxlLmlkLCBhbGlhc1JlbGF0aW9uc2hpcFRhYmxlW2Ake2ZpZWxkLnJlbGF0aW9uVG99SURgXSksXG4gICAgICAgICAgICB0YWJsZTogbmV3QWxpYXNUYWJsZSxcbiAgICAgICAgICB9KVxuXG4gICAgICAgICAgaWYgKG5ld0NvbGxlY3Rpb25QYXRoID09PSAnJykge1xuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgY29sdW1uTmFtZTogYCR7ZmllbGQucmVsYXRpb25Ub31JRGAsXG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgICBmaWVsZCxcbiAgICAgICAgICAgICAgdGFibGU6IGFsaWFzUmVsYXRpb25zaGlwVGFibGUsXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfVxuICAgICAgICB9IGVsc2UgaWYgKG5ld0NvbGxlY3Rpb25QYXRoID09PSAndmFsdWUnKSB7XG4gICAgICAgICAgY29uc3QgdGFibGVDb2x1bW5zTmFtZXMgPSBmaWVsZC5yZWxhdGlvblRvLm1hcChcbiAgICAgICAgICAgIChyZWxhdGlvblRvKSA9PiBgXCIke2FsaWFzUmVsYXRpb25zaGlwVGFibGVOYW1lfVwiLlwiJHt0b1NuYWtlQ2FzZShyZWxhdGlvblRvKX1faWRcImAsXG4gICAgICAgICAgKVxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkLFxuICAgICAgICAgICAgcmF3Q29sdW1uOiBzcWwucmF3KGBDT0FMRVNDRSgke3RhYmxlQ29sdW1uc05hbWVzLmpvaW4oJywgJyl9KWApLFxuICAgICAgICAgICAgdGFibGU6IGFsaWFzUmVsYXRpb25zaGlwVGFibGUsXG4gICAgICAgICAgfVxuICAgICAgICB9IGVsc2UgaWYgKG5ld0NvbGxlY3Rpb25QYXRoID09PSAncmVsYXRpb25UbycpIHtcbiAgICAgICAgICBjb25zdCByZWxhdGlvblRvID0gQXJyYXkuaXNBcnJheShmaWVsZC5yZWxhdGlvblRvKSA/IGZpZWxkLnJlbGF0aW9uVG8gOiBbZmllbGQucmVsYXRpb25Ub11cblxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkLFxuICAgICAgICAgICAgZ2V0Tm90TnVsbENvbHVtbkJ5VmFsdWU6ICh2YWwpID0+IHtcbiAgICAgICAgICAgICAgY29uc3QgbWF0Y2hlZFJlbGF0aW9uID0gcmVsYXRpb25Uby5maW5kKChyZWxhdGlvbikgPT4gcmVsYXRpb24gPT09IHZhbClcbiAgICAgICAgICAgICAgaWYgKG1hdGNoZWRSZWxhdGlvbikgcmV0dXJuIGAke21hdGNoZWRSZWxhdGlvbn1JRGBcbiAgICAgICAgICAgICAgcmV0dXJuIHVuZGVmaW5lZFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIHRhYmxlOiBhbGlhc1JlbGF0aW9uc2hpcFRhYmxlLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICB0aHJvdyBuZXcgQVBJRXJyb3IoJ05vdCBzdXBwb3J0ZWQnKVxuICAgICAgICB9XG5cbiAgICAgICAgcmV0dXJuIGdldFRhYmxlQ29sdW1uRnJvbVBhdGgoe1xuICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgYWxpYXNUYWJsZTogbmV3QWxpYXNUYWJsZSxcbiAgICAgICAgICBjb2xsZWN0aW9uUGF0aDogbmV3Q29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgZmllbGRzOiByZWxhdGlvbnNoaXBGaWVsZHMsXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICA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XRCLGFBQWEsRUFBRWdCLE1BQU1LLElBQUksQ0FBQyxDQUFDLENBQUMsR0FDMURnRSxXQUFXLENBQUMsQ0FBQyxFQUFFckYsYUFBYSxFQUFFZ0IsTUFBTUssSUFBSSxDQUFDLENBQUMsQ0FBQzt3QkFFN0MsT0FBTzs0QkFDTEksWUFBWSxDQUFDLEVBQUV6QixhQUFhLEVBQUVnQixNQUFNSyxJQUFJLENBQUMsQ0FBQzs0QkFDMUNsQjs0QkFDQWE7NEJBQ0FQLGNBQWNBOzRCQUNka0IsT0FBTzBEO3dCQUNUO29CQUNGO2dCQUNGO1FBQ0Y7SUFDRjtJQUVBLE1BQU0sSUFBSTFCLGdCQUFRLENBQUMsQ0FBQyw4QkFBOEIsRUFBRTVDLFVBQVUsQ0FBQztBQUNqRSJ9
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@payloadcms/db-postgres",
|
3
|
-
"version": "0.2.
|
3
|
+
"version": "0.2.2",
|
4
4
|
"description": "The officially supported Postgres database adapter for Payload",
|
5
5
|
"repository": "https://github.com/payloadcms/payload",
|
6
6
|
"license": "MIT",
|
@@ -25,8 +25,8 @@
|
|
25
25
|
"devDependencies": {
|
26
26
|
"@types/pg": "8.10.2",
|
27
27
|
"@types/to-snake-case": "1.0.0",
|
28
|
-
"
|
29
|
-
"
|
28
|
+
"payload": "2.5.0",
|
29
|
+
"@payloadcms/eslint-config": "1.0.0"
|
30
30
|
},
|
31
31
|
"peerDependencies": {
|
32
32
|
"payload": "^2.0.0"
|