@payloadcms/db-postgres 0.1.13 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -1 +1 @@
1
- {"version":3,"file":"findMany.d.ts","sourceRoot":"","sources":["../../src/find/findMany.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,KAAK,EAAE,KAAK,EAA8B,MAAM,eAAe,CAAA;AAItE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAQ/C,KAAK,IAAI,GAAG,IAAI,CAAC,QAAQ,EAAE,YAAY,CAAC,GAAG;IACzC,OAAO,EAAE,eAAe,CAAA;IACxB,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,SAAS,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,eAAO,MAAM,QAAQ,iHAYlB,IAAI;;;;;;;;;;;EA8KN,CAAA"}
1
+ {"version":3,"file":"findMany.d.ts","sourceRoot":"","sources":["../../src/find/findMany.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAA;AAChD,OAAO,KAAK,EAAE,KAAK,EAA8B,MAAM,eAAe,CAAA;AAItE,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,UAAU,CAAA;AAQ/C,KAAK,IAAI,GAAG,IAAI,CAAC,QAAQ,EAAE,YAAY,CAAC,GAAG;IACzC,OAAO,EAAE,eAAe,CAAA;IACxB,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,SAAS,EAAE,MAAM,CAAA;CAClB,CAAA;AAED,eAAO,MAAM,QAAQ,iHAYlB,IAAI;;;;;;;;;;;EA+KN,CAAA"}
@@ -21,7 +21,7 @@ function _interop_require_default(obj) {
21
21
  const findMany = async function find({ adapter, fields, limit: limitArg, locale, page = 1, pagination, req = {}, skip, sort, tableName, where: whereArg }) {
22
22
  const db = adapter.sessions[req.transactionID]?.db || adapter.drizzle;
23
23
  const table = adapter.tables[tableName];
24
- let limit = limitArg ?? 10;
24
+ const limit = limitArg ?? 10;
25
25
  let totalDocs;
26
26
  let totalPages;
27
27
  let hasPrevPage;
@@ -37,6 +37,7 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
37
37
  where: whereArg
38
38
  });
39
39
  const orderedIDMap = {};
40
+ let orderedIDs;
40
41
  const selectDistinctMethods = [];
41
42
  if (orderBy?.order && orderBy?.column) {
42
43
  selectDistinctMethods.push({
@@ -116,7 +117,8 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
116
117
  selectDistinctResult.forEach(({ id }, i)=>{
117
118
  orderedIDMap[id] = i;
118
119
  });
119
- findManyArgs.where = (0, _drizzleorm.inArray)(adapter.tables[tableName].id, Object.keys(orderedIDMap));
120
+ orderedIDs = Object.keys(orderedIDMap);
121
+ findManyArgs.where = (0, _drizzleorm.inArray)(adapter.tables[tableName].id, orderedIDs);
120
122
  } else {
121
123
  findManyArgs.limit = limitArg === 0 ? undefined : limitArg;
122
124
  const offset = skip || (page - 1) * limitArg;
@@ -127,7 +129,7 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
127
129
  findManyArgs.orderBy = orderBy.order(orderBy.column);
128
130
  }
129
131
  const findPromise = db.query[tableName].findMany(findManyArgs);
130
- if (pagination !== false || selectDistinctResult?.length > limit) {
132
+ if (pagination !== false && (orderedIDs ? orderedIDs?.length >= limit : true)) {
131
133
  const selectCountMethods = [];
132
134
  joinAliases.forEach(({ condition, table })=>{
133
135
  selectCountMethods.push({
@@ -167,9 +169,8 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
167
169
  if (Object.keys(orderedIDMap).length > 0) {
168
170
  rawDocs.sort((a, b)=>orderedIDMap[a.id] - orderedIDMap[b.id]);
169
171
  }
170
- if (pagination === false) {
172
+ if (pagination === false || !totalDocs) {
171
173
  totalDocs = rawDocs.length;
172
- limit = totalDocs;
173
174
  totalPages = 1;
174
175
  pagingCounter = 1;
175
176
  hasPrevPage = false;
@@ -196,4 +197,4 @@ const findMany = async function find({ adapter, fields, limit: limitArg, locale,
196
197
  };
197
198
  };
198
199
 
199
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9maW5kL2ZpbmRNYW55LnRzIl0sInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB0eXBlIHsgRmluZEFyZ3MgfSBmcm9tICdwYXlsb2FkL2RhdGFiYXNlJ1xuaW1wb3J0IHR5cGUgeyBGaWVsZCwgUGF5bG9hZFJlcXVlc3QsIFR5cGVXaXRoSUQgfSBmcm9tICdwYXlsb2FkL3R5cGVzJ1xuXG5pbXBvcnQgeyBpbkFycmF5LCBzcWwgfSBmcm9tICdkcml6emxlLW9ybSdcblxuaW1wb3J0IHR5cGUgeyBQb3N0Z3Jlc0FkYXB0ZXIgfSBmcm9tICcuLi90eXBlcydcbmltcG9ydCB0eXBlIHsgQ2hhaW5lZE1ldGhvZHMgfSBmcm9tICcuL2NoYWluTWV0aG9kcydcblxuaW1wb3J0IGJ1aWxkUXVlcnkgZnJvbSAnLi4vcXVlcmllcy9idWlsZFF1ZXJ5J1xuaW1wb3J0IHsgdHJhbnNmb3JtIH0gZnJvbSAnLi4vdHJhbnNmb3JtL3JlYWQnXG5pbXBvcnQgeyBidWlsZEZpbmRNYW55QXJncyB9IGZyb20gJy4vYnVpbGRGaW5kTWFueUFyZ3MnXG5pbXBvcnQgeyBjaGFpbk1ldGhvZHMgfSBmcm9tICcuL2NoYWluTWV0aG9kcydcblxudHlwZSBBcmdzID0gT21pdDxGaW5kQXJncywgJ2NvbGxlY3Rpb24nPiAmIHtcbiAgYWRhcHRlcjogUG9zdGdyZXNBZGFwdGVyXG4gIGZpZWxkczogRmllbGRbXVxuICB0YWJsZU5hbWU6IHN0cmluZ1xufVxuXG5leHBvcnQgY29uc3QgZmluZE1hbnkgPSBhc3luYyBmdW5jdGlvbiBmaW5kKHtcbiAgYWRhcHRlcixcbiAgZmllbGRzLFxu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HQUFHLEdBQUc7UUFDeEM0QixRQUFROUQsSUFBSSxDQUFDLENBQUMrRCxHQUFHQyxJQUFNM0MsWUFBWSxDQUFDMEMsRUFBRWYsRUFBRSxDQUFDLEdBQUczQixZQUFZLENBQUMyQyxFQUFFaEIsRUFBRSxDQUFDO0lBQ2hFO0lBRUEsSUFBSW5ELGVBQWUsU0FBUyxDQUFDYSxXQUFXO1FBQ3RDQSxZQUFZb0QsUUFBUTVCLE1BQU07UUFDMUJ2QixhQUFhO1FBQ2JHLGdCQUFnQjtRQUNoQkYsY0FBYztRQUNkQyxjQUFjO0lBQ2hCO0lBRUEsTUFBTWdDLE9BQU9pQixRQUFRRyxHQUFHLENBQUMsQ0FBQ0M7UUFDeEIsT0FBT0MsSUFBQUEsZUFBUyxFQUFDO1lBQ2ZDLFFBQVE3RSxRQUFROEUsT0FBTyxDQUFDRCxNQUFNO1lBQzlCRjtZQUNBMUU7UUFDRjtJQUNGO0lBRUEsT0FBTztRQUNMcUQ7UUFDQWhDO1FBQ0FEO1FBQ0FuQjtRQUNBcUQsVUFBVWpDLGNBQWNqQixPQUFPLElBQUk7UUFDbkNBO1FBQ0FrQjtRQUNBaUMsVUFBVW5DLGNBQWNoQixPQUFPLElBQUk7UUFDbkNjO1FBQ0FDO0lBQ0Y7QUFDRiJ9
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EAAE,IAAI,EAAmB,qBAAqB,EAAE,MAAM,SAAS,CAAA;AAmC3E,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAE7D,wBAAgB,eAAe,CAAC,IAAI,EAAE,IAAI,GAAG,qBAAqB,CA4DjE"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAMA,OAAO,KAAK,EAAE,IAAI,EAAmB,qBAAqB,EAAE,MAAM,SAAS,CAAA;AAmC3E,YAAY,EAAE,eAAe,EAAE,aAAa,EAAE,MAAM,SAAS,CAAA;AAE7D,wBAAgB,eAAe,CAAC,IAAI,EAAE,IAAI,GAAG,qBAAqB,CA4DjE"}
package/dist/index.js CHANGED
@@ -8,6 +8,7 @@ Object.defineProperty(exports, "postgresAdapter", {
8
8
  return postgresAdapter;
9
9
  }
10
10
  });
11
+ const _fs = /*#__PURE__*/ _interop_require_default(require("fs"));
11
12
  const _path = /*#__PURE__*/ _interop_require_default(require("path"));
12
13
  const _database = require("payload/database");
13
14
  const _connect = require("./connect");
@@ -49,7 +50,7 @@ function _interop_require_default(obj) {
49
50
  }
50
51
  function postgresAdapter(args) {
51
52
  function adapter({ payload }) {
52
- const migrationDir = args.migrationDir || _path.default.resolve(process.cwd(), 'src/migrations');
53
+ const migrationDir = findMigrationDir(args.migrationDir);
53
54
  (0, _extendWebpackConfig.extendWebpackConfig)(payload.config);
54
55
  (0, _extendViteConfig.extendViteConfig)(payload.config);
55
56
  return (0, _database.createDatabaseAdapter)({
@@ -57,6 +58,7 @@ function postgresAdapter(args) {
57
58
  // Postgres-specific
58
59
  drizzle: undefined,
59
60
  enums: {},
61
+ fieldConstraints: {},
60
62
  pool: undefined,
61
63
  poolOptions: args.pool,
62
64
  push: args.push,
@@ -64,7 +66,6 @@ function postgresAdapter(args) {
64
66
  schema: {},
65
67
  sessions: {},
66
68
  tables: {},
67
- fieldConstraints: {},
68
69
  // DatabaseAdapter
69
70
  beginTransaction: _beginTransaction.beginTransaction,
70
71
  commitTransaction: _commitTransaction.commitTransaction,
@@ -103,5 +104,37 @@ function postgresAdapter(args) {
103
104
  }
104
105
  return adapter;
105
106
  }
107
+ /**
108
+ * Attempt to find migrations directory.
109
+ *
110
+ * Checks for the following directories in order:
111
+ * - `migrationDir` argument from Payload config
112
+ * - `src/migrations`
113
+ * - `dist/migrations`
114
+ * - `migrations`
115
+ *
116
+ * Defaults to `src/migrations`
117
+ *
118
+ * @param migrationDir
119
+ * @returns
120
+ */ function findMigrationDir(migrationDir) {
121
+ const cwd = process.cwd();
122
+ const srcDir = _path.default.resolve(cwd, 'src/migrations');
123
+ const distDir = _path.default.resolve(cwd, 'dist/migrations');
124
+ const relativeMigrations = _path.default.resolve(cwd, 'migrations');
125
+ // Use arg if provided
126
+ if (migrationDir) return migrationDir;
127
+ // Check other common locations
128
+ if (_fs.default.existsSync(srcDir)) {
129
+ return srcDir;
130
+ }
131
+ if (_fs.default.existsSync(distDir)) {
132
+ return distDir;
133
+ }
134
+ if (_fs.default.existsSync(relativeMigrations)) {
135
+ return relativeMigrations;
136
+ }
137
+ return srcDir;
138
+ }
106
139
 
107
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uL3NyYy9pbmRleC50cyJdLCJzb3VyY2VzQ29udGVudCI6WyJpbXBvcnQgdHlwZSB7IFBheWxvYWQgfSBmcm9tICdwYXlsb2FkJ1xuXG5pbXBvcnQgcGF0aCBmcm9tICdwYXRoJ1xuaW1wb3J0IHsgY3JlYXRlRGF0YWJhc2VBZGFwdGVyIH0gZnJvbSAncGF5bG9hZC9kYXRhYmFzZSdcblxuaW1wb3J0IHR5cGUgeyBBcmdzLCBQb3N0Z3Jlc0FkYXB0ZXIsIFBvc3RncmVzQWRhcHRlclJlc3VsdCB9IGZyb20gJy4vdHlwZXMnXG5cbmltcG9ydCB7IGNvbm5lY3QgfSBmcm9tICcuL2Nvbm5lY3QnXG5pbXBvcnQgeyBjcmVhdGUgfSBmcm9tICcuL2NyZWF0ZSdcbmltcG9ydCB7IGNyZWF0ZUdsb2JhbCB9IGZyb20gJy4vY3JlYXRlR2xvYmFsJ1xuaW1wb3J0IHsgY3JlYXRlR2xvYmFsVmVyc2lvbiB9IGZyb20gJy4vY3JlYXRlR2xvYmFsVmVyc2lvbidcbmltcG9ydCB7IGNyZWF0ZU1pZ3JhdGlvbiB9IGZyb20gJy4vY3JlYXRlTWlncmF0aW9uJ1xuaW1wb3J0IHsgY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,EAAE,eAAe,CAAA;IACxB,MAAM,EAAE,KAAK,EAAE,CAAA;IACf,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,SAAS,EAAE,MAAM,CAAA;IACjB,KAAK,EAAE,KAAK,CAAA;CACb,CAAA;AAED,KAAK,MAAM,GAAG;IACZ,WAAW,EAAE,qBAAqB,CAAA;IAClC,KAAK,EAAE,eAAe,CAAA;IACtB,OAAO,EAAE;QACP,MAAM,EAAE,aAAa,CAAA;QACrB,KAAK,EAAE,OAAO,GAAG,GAAG,OAAO,IAAI,CAAA;KAChC,CAAA;IACD,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,aAAa,CAAC,CAAA;IAC3C,KAAK,EAAE,GAAG,CAAA;CACX,CAAA;AACD,QAAA,MAAM,UAAU,wEAOb,cAAc,KAAG,QAAQ,MAAM,CA8EjC,CAAA;AAED,eAAe,UAAU,CAAA"}
@@ -30,19 +30,24 @@ const buildQuery = async function buildQuery({ adapter, fields, locale, sort, ta
30
30
  sortPath = sort;
31
31
  orderBy.order = _drizzleorm.asc;
32
32
  }
33
- const { columnName: sortTableColumnName, table: sortTable } = (0, _getTableColumnFromPath.getTableColumnFromPath)({
34
- adapter,
35
- collectionPath: sortPath,
36
- fields,
37
- joinAliases,
38
- joins,
39
- locale,
40
- pathSegments: sortPath.replace(/__/g, '.').split('.'),
41
- selectFields,
42
- tableName
43
- });
44
- orderBy.column = sortTable[sortTableColumnName];
45
- } else {
33
+ try {
34
+ const { columnName: sortTableColumnName, table: sortTable } = (0, _getTableColumnFromPath.getTableColumnFromPath)({
35
+ adapter,
36
+ collectionPath: sortPath,
37
+ fields,
38
+ joinAliases,
39
+ joins,
40
+ locale,
41
+ pathSegments: sortPath.replace(/__/g, '.').split('.'),
42
+ selectFields,
43
+ tableName
44
+ });
45
+ orderBy.column = sortTable?.[sortTableColumnName];
46
+ } catch (err) {
47
+ // continue
48
+ }
49
+ }
50
+ if (!orderBy?.column) {
46
51
  orderBy.order = _drizzleorm.desc;
47
52
  const createdAt = adapter.tables[tableName]?.createdAt;
48
53
  if (createdAt) {
@@ -77,4 +82,4 @@ const buildQuery = async function buildQuery({ adapter, fields, locale, sort, ta
77
82
  };
78
83
  const _default = buildQuery;
79
84
 
80
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9xdWVyaWVzL2J1aWxkUXVlcnkudHMiXSwic291cmNlc0NvbnRlbnQiOlsiaW1wb3J0IHR5cGUgeyBTUUwgfSBmcm9tICdkcml6emxlLW9ybSdcbmltcG9ydCB0eXBlIHsgRmllbGQsIFdoZXJlIH0gZnJvbSAncGF5bG9hZC90eXBlcydcblxuaW1wb3J0IHsgYXNjLCBkZXNjIH0gZnJvbSAnZHJpenpsZS1vcm0nXG5cbmltcG9ydCB0eXBlIHsgR2VuZXJpY0NvbHVtbiwgR2VuZXJpY1RhYmxlLCBQb3N0Z3Jlc0FkYXB0ZXIgfSBmcm9tICcuLi90eXBlcydcblxuaW1wb3J0IHsgZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCB9IGZyb20gJy4vZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCdcbmltcG9ydCB7IHBhcnNlUGFyYW1zIH0gZnJvbSAnLi9wYXJzZVBhcmFtcydcblxuZXhwb3J0IHR5cGUgQnVpbGRRdWVyeUpvaW5zID0gUmVjb3JkPHN0cmluZywgU1FMPlxuXG5leHBvcnQgdHlwZSBCdWlsZFF1ZXJ5Sm9pbkFsaWFzZXMgPSB7XG4gIGNvbmRpdGlvbjogU1FMXG4gIHRhYmxlOiBHZW5lcmljVGFibGVcbn1bXVxuXG50eXBlIEJ1aWxkUXVlcnlBcmdzID0ge1xuICBhZGFwdGVyOiBQb3N0Z3Jlc0FkYXB0ZXJcbiAgZmllbGRzOiBGaWVsZFtdXG4gIGxvY2FsZT86IHN0cmluZ1xuICBzb3J0Pzogc3RyaW5nX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KAAK,EAAE,YAAY,CAAA;CACpB,CAAA;AAED,KAAK,IAAI,GAAG;IACV,OAAO,EAAE,eAAe,CAAA;IACxB,UAAU,CAAC,EAAE,YAAY,CAAA;IACzB,cAAc,EAAE,MAAM,CAAA;IACtB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,cAAc,CAAC,EAAE,MAAM,CAAA;IACvB,WAAW,CAAC,EAAE,UAAU,EAAE,CAAA;IAC1B,MAAM,EAAE,CAAC,KAAK,GAAG,UAAU,CAAC,EAAE,CAAA;IAC9B,WAAW,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,WAmXT,CAAA"}
@@ -233,6 +233,9 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
233
233
  table: adapter.tables[newTableName]
234
234
  };
235
235
  }
236
+ if (pathSegments[1] === 'blockType') {
237
+ throw new _errors.APIError('Querying on blockType is not supported');
238
+ }
236
239
  break;
237
240
  }
238
241
  case 'relationship':
@@ -346,4 +349,4 @@ const getTableColumnFromPath = ({ adapter, aliasTable, collectionPath, columnPre
346
349
  throw new _errors.APIError(`Cannot find field for path at ${fieldPath}`);
347
350
  };
348
351
 
349
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy9xdWVyaWVzL2dldFRhYmxlQ29sdW1uRnJvbVBhdGgudHMiXSwic291cmNlc0NvbnRlbnQiOlsiLyogZXNsaW50LWRpc2FibGUgbm8tcGFyYW0tcmVhc3NpZ24gKi9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iAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICBmaWVsZHM6IGZpZWxkLnRhYnMubWFwKCh0YWIpID0+ICh7XG4gICAgICAgICAgICAuLi50YWIsXG4gICAgICAgICAgICB0eXBlOiAndGFiJyxcbiAgICAgICAgICB9KSksXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuICAgICAgY2FzZSAndGFiJzoge1xuICAgICAgICBpZiAodGFiSGFzTmFtZShmaWVsZCkpIHtcbiAgICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgICBqb2lucyxcbiAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgICAgcm9vdFRhYmxlTmFtZSxcbiAgICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgIH0pXG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGdldFRhYmxlQ29sdW1uRnJvbVBhdGgoe1xuICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICBjb2xsZWN0aW9uUGF0aCxcbiAgICAgICAgICBjb2x1bW5QcmVmaXgsXG4gICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgZmllbGRzOiBmaWVsZC5maWVsZHMsXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICBjYXNlICdncm91cCc6IHtcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2xvY2FsZXNgXG5cbiAgICAgICAgICBqb2luc1t0YWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICAgIGlmIChsb2NhbGUgIT09ICdhbGwnKSB7XG4gICAgICAgICAgICBjb25zdHJhaW50cy5wdXNoKHtcbiAgICAgICAgICAgICAgY29sdW1uTmFtZTogJ19sb2NhbGUnLFxuICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgdmFsdWU6IGxvY2FsZSxcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGFsaWFzVGFibGUsXG4gICAgICAgICAgY29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYXJyYXknOiB7XG4gICAgICAgIG5ld1RhYmxlTmFtZSA9IGAke3RhYmxlTmFtZX1fJHt0b1NuYWtlQ2FzZShmaWVsZC5uYW1lKX1gXG4gICAgICAgIGNvbnN0cmFpbnRQYXRoID0gYCR7Y29uc3RyYWludFBhdGh9JHtmaWVsZC5uYW1lfS4lLmBcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gYW5kKFxuICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fbG9jYWxlLCBsb2NhbGUpLFxuICAgICAgICAgIClcbiAgICAgICAgICBpZiAobG9jYWxlICE9PSAnYWxsJykge1xuICAgICAgICAgICAgY29uc3RyYWludHMucHVzaCh7XG4gICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgdGFibGU6IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0sXG4gICAgICAgICAgICAgIHZhbHVlOiBsb2NhbGUsXG4gICAgICAgICAgICB9KVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYmxvY2tzJzoge1xuICAgICAgICBsZXQgYmxvY2tUYWJsZUNvbHVtbjogVGFibGVDb2x1bW5cbiAgICAgICAgbGV0IG5ld1RhYmxlTmFtZTogc3RyaW5nXG4gICAgICAgIGNvbnN0IGhhc0Jsb2NrRmllbGQgPSBmaWVsZC5ibG9ja3Muc29tZSgoYmxvY2spID0+IHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2Jsb2Nrc18ke3RvU25ha2VDYXNlKGJsb2NrLnNsdWcpfWBcbiAgICAgICAgICBsZXQgcmVzdWx0XG4gICAgICAgICAgY29uc3QgYmxvY2tDb25zdHJhaW50cyA9IFtdXG4gICAgICAgICAgY29uc3QgYmxvY2tTZWxlY3RGaWVsZHMgPSB7fVxuICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICByZXN1bHQgPSBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICAgICAgY29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRQYXRoOiAnJyxcbiAgICAgICAgICAgICAgY29uc3RyYWludHM6IGJsb2NrQ29uc3RyYWludHMsXG4gICAgICAgICAgICAgIGZpZWxkczogYmxvY2suZmllbGRzLFxuICAgICAgICAgICAgICBqb2luQWxpYXNlcyxcbiAgICAgICAgICAgICAgam9pbnMsXG4gICAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgICAgcGF0aFNlZ21lbnRzOiBwYXRoU2VnbWVudHMuc2xpY2UoMSksXG4gICAgICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgICAgIHNlbGVjdEZpZWxkczogYmxvY2tTZWxlY3RGaWVsZHMsXG4gICAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgICAgfSlcbiAgICAgICAgICB9IGNhdGNoIChlcnJvcikge1xuICAgICAgICAgICAgLy8gdGhpcyBpcyBmaW5lLCBub3QgZXZlcnkgYmxvY2sgd2lsbCBoYXZlIHRoZSBmaWVsZFxuICAgICAgICAgIH1cbiAgICAgICAgICBpZiAoIXJlc3VsdCkge1xuICAgICAgICAgICAgcmV0dXJuXG4gICAgICAgICAgfVxuICAgICAgICAgIGJsb2NrVGFibGVDb2x1bW4gPSByZXN1bHRcbiAgICAgICAgICBjb25zdHJhaW50cyA9IGNvbnN0cmFpbnRzLmNvbmNhdChibG9ja0NvbnN0cmFpbnRzKVxuICAgICAgICAgIHNlbGVjdEZpZWxkcyA9IHsgLi4uc2VsZWN0RmllbGRzLCAuLi5ibG9ja1NlbGVjdEZpZWxkcyB9XG4gICAgICAgICAgaWYgKGZpZWxkLmxvY2FsaXplZCAmJiBhZGFwdGVyLnBheWxvYWQuY29uZmlnLmxvY2FsaXphdGlvbikge1xuICAgICAgICAgICAgam9pbnNbbmV3VGFibGVOYW1lXSA9IGFuZChcbiAgICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgICBlcShhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLl9sb2NhbGUsIGxvY2FsZSksXG4gICAgICAgICAgICApXG4gICAgICAgICAgICBpZiAobG9jYWxlKSB7XG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRzLnB1c2goe1xuICAgICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogbG9jYWxlLFxuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW3RhYmxlTmFtZV0uaWQsXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0uX3BhcmVudElELFxuICAgICAgICAgICAgKVxuICAgICAgICAgIH1cbiAgICAgICAgICByZXR1cm4gcmVzdWx0XG4gICAgICAgIH0pXG4gICAgICAgIGlmIChoYXNCbG9ja0ZpZWxkKSB7XG4gICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgIGNvbHVtbk5hbWU6IGJsb2NrVGFibGVDb2x1bW4uY29sdW1uTmFtZSxcbiAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgZmllbGQ6IGJsb2NrVGFibGVDb2x1bW4uZmllbGQsXG4gICAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICAgIHJhd0NvbHVtbjogYmxvY2tUYWJsZUNvbHVtbi5yYXdDb2x1bW4sXG4gICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICB9XG4gICAgICAgIH1cbiAgICAgICAgYnJlYWtcbiAgICAgIH1cblxuICAgICAgY2FzZSAncmVsYXRpb25zaGlwJzpcbiAgICAgIGNhc2UgJ3VwbG9hZCc6IHtcbiAgICAgICAgbGV0IHJlbGF0aW9uc2hpcEZpZWxkc1xuICAgICAgICBjb25zdCByZWxhdGlvblRhYmxlTmFtZSA9IGAke3Jvb3RUYWJsZU5hbWV9X3JlbHNgXG4gICAgICAgIGNvbnN0IG5ld0NvbGxlY3Rpb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cnKSB7XG4gICAgICAgICAgbmV3VGFibGVOYW1lID0gYCR7dG9TbmFrZUNhc2UoZmllbGQucmVsYXRpb25Ubyl9YFxuICAgICAgICAgIC8vIHBhcmVudCB0byByZWxhdGlvbnNoaXAgam9pbiB0YWJsZVxuICAgICAgICAgIHJlbGF0aW9uc2hpcEZpZWxkcyA9IGFkYXB0ZXIucGF5bG9hZC5jb2xsZWN0aW9uc1tmaWVsZC5yZWxhdGlvblRvXS5jb25maWcuZmllbGRzXG5cbiAgICAgICAgICBuZXdBbGlhc1RhYmxlID0gYWxpYXMoYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSwgdG9TbmFrZUNhc2UodXVpZCgpKSlcblxuICAgICAgICAgIGpvaW5BbGlhc2VzLnB1c2goe1xuICAgICAgICAgICAgY29uZGl0aW9uOiBlcShuZXdBbGlhc1RhYmxlLmlkLCBhbGlhc1JlbGF0aW9uc2hpcFRhYmxlW2Ake2ZpZWxkLnJlbGF0aW9uVG99SURgXSksXG4gICAgICAgICAgICB0YWJsZTogbmV3QWxpYXNUYWJsZSxcbiAgICAgICAgICB9KVxuXG4gICAgICAgICAgaWYgKG5ld0NvbGxlY3Rpb25QYXRoID09PSAnJykge1xuICAgICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgICAgY29sdW1uTmFtZTogYCR7ZmllbGQucmVsYXRpb25Ub31JRGAsXG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgICBmaWVsZCxcbiAgICAgICAgICAgICAgdGFibGU6IGFsaWFzUmVsYXRpb25zaGlwVGFibGUsXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfVxuICAgICAgICB9IGVsc2UgaWYgKG5ld0NvbGxlY3Rpb25QYXRoID09PSAndmFsdWUnKSB7XG4gICAgICAgICAgY29uc3QgdGFibGVDb2x1bW5zTmFtZXMgPSBmaWVsZC5yZWxhdGlvblRvLm1hcChcbiAgICAgICAgICAgIChyZWxhdGlvblRvKSA9PiBgXCIke2FsaWFzUmVsYXRpb25zaGlwVGFibGVOYW1lfVwiLlwiJHt0b1NuYWtlQ2FzZShyZWxhdGlvblRvKX1faWRcImAsXG4gICAgICAgICAgKVxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkLFxuICAgICAgICAgICAgcmF3Q29sdW1uOiBzcWwucmF3KGBDT0FMRVNDRSgke3RhYmxlQ29sdW1uc05hbWVzLmpvaW4oJywgJyl9KWApLFxuICAgICAgICAgICAgdGFibGU6IGFsaWFzUmVsYXRpb25zaGlwVGFibGUsXG4gICAgICAgICAgfVxuICAgICAgICB9IGVsc2UgaWYgKG5ld0NvbGxlY3Rpb25QYXRoID09PSAncmVsYXRpb25UbycpIHtcbiAgICAgICAgICBjb25zdCByZWxhdGlvblRvID0gQXJyYXkuaXNBcnJheShmaWVsZC5yZWxhdGlvblRvKSA/IGZpZWxkLnJlbGF0aW9uVG8gOiBbZmllbGQucmVsYXRpb25Ub11cblxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkLFxuICAgICAgICAgICAgZ2V0Tm90TnVsbENvbHVtbkJ5VmFsdWU6ICh2YWwpID0+IHtcbiAgICAgICAgICAgICAgY29uc3QgbWF0Y2hlZFJlbGF0aW9uID0gcmVsYXRpb25Uby5maW5kKChyZWxhdGlvbikgPT4gcmVsYXRpb24gPT09IHZhbClcbiAgICAgICAgICAgICAgaWYgKG1hdGNoZWRSZWxhdGlvbikgcmV0dXJuIGAke21hdGNoZWRSZWxhdGlvbn1JRGBcbiAgICAgICAgICAgICAgcmV0dXJuIHVuZGVmaW5lZFxuICAgICAgICAgICAgfSxcbiAgICAgICAgICAgIHRhYmxlOiBhbGlhc1JlbGF0aW9uc2hpcFRhYmxlLFxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICB0aHJvdyBu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gIGNvbnN0IHBhcmVudFRhYmxlID0gYWxpYXNUYWJsZSB8fCBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdXG5cbiAgICAgICAgICAgIGpvaW5zW25ld1RhYmxlTmFtZV0gPSBlcShwYXJlbnRUYWJsZS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpXG5cbiAgICAgICAgICAgIGFsaWFzVGFibGUgPSB1bmRlZmluZWRcblxuICAgICAgICAgICAgaWYgKGxvY2FsZSAhPT0gJ2FsbCcpIHtcbiAgICAgICAgICAgICAgY29uc3RyYWludHMucHVzaCh7XG4gICAgICAgICAgICAgICAgY29sdW1uTmFtZTogJ19sb2NhbGUnLFxuICAgICAgICAgICAgICAgIHRhYmxlOiBhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLFxuICAgICAgICAgICAgICAgIHZhbHVlOiBsb2NhbGUsXG4gICAgICAgICAgICAgIH0pXG4gICAgICAgICAgICB9XG4gICAgICAgICAgfVxuXG4gICAgICAgICAgY29uc3QgdGFyZ2V0VGFibGUgPSBhbGlhc1RhYmxlIHx8IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV1cblxuICAgICAgICAgIHNlbGVjdEZpZWxkc1tgJHtuZXdUYWJsZU5hbWV9LiR7Y29sdW1uUHJlZml4fSR7ZmllbGQubmFtZX1gXSA9XG4gICAgICAgICAgICB0YXJnZXRUYWJsZVtgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfWBdXG5cbiAgICAgICAgICByZXR1cm4ge1xuICAgICAgICAgICAgY29sdW1uTmFtZTogYCR7Y29sdW1uUHJlZml4fSR7ZmllbGQubmFtZX1gLFxuICAgICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgICBmaWVsZCxcbiAgICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLFxuICAgICAgICAgICAgdGFibGU6IHRhcmdldFRhYmxlLF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G8gdGFrZSBpdCBvdXQgYW5kIHVzZSBpdCBhcyB0aGUgbG9jYWxlIGZyb20gdGhpcyBwb2ludCBvblxuICAgIGlmICgnbG9jYWxpemVkJyBpbiBmaWVsZCAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgIGNvbnN0IG1hdGNoZWRMb2NhbGUgPSBhZGFwdGVyLnBheWxvYWQuY29uZmlnLmxvY2FsaXphdGlvbi5sb2NhbGVDb2Rlcy5maW5kKFxuICAgICAgICAobG9jYWxlKSA9PiBsb2NhbGUgPT09IHBhdGhTZWdtZW50c1sxXSxcbiAgICAgIClcblxuICAgICAgaWYgKG1hdGNoZWRMb2NhbGUpIHtcbiAgICAgICAgbG9jYWxlID0gbWF0Y2hlZExvY2FsZVxuICAgICAgICBwYXRoU2VnbWVudHMuc3BsaWNlKDEsIDEpXG4gICAgICB9XG4gICAgfVxuXG4gICAgc3dpdGNoIChmaWVsZC50eXBlKSB7XG4gICAgICBjYXNlICd0YWJzJzoge1xuICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICBhbGlhc1RhYmxlLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbHVtblByZWZpeCxcbiAgICAgICAgICBjb25zdHJhaW50UGF0aCxcbiAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICBmaWVsZHM6IGZpZWxkLnRhYnMubWFwKCh0YWIpID0+ICh7XG4gICAgICAgICAgICAuLi50YWIsXG4gICAgICAgICAgICB0eXBlOiAndGFiJyxcbiAgICAgICAgICB9KSksXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuICAgICAgY2FzZSAndGFiJzoge1xuICAgICAgICBpZiAodGFiSGFzTmFtZShmaWVsZCkpIHtcbiAgICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gcm9tUGF0aCh7XG4gICAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgICAgY29sdW1uUHJlZml4OiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfV9gLFxuICAgICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgICBqb2lucyxcbiAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgICAgcm9vdFRhYmxlTmFtZSxcbiAgICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgIH0pXG4gICAgICAgIH1cbiAgICAgICAgcmV0dXJuIGdldFRhYmxlQ29sdW1uRnJvbVBhdGgoe1xuICAgICAgICAgIGFkYXB0ZXIsXG4gICAgICAgICAgYWxpYXNUYWJsZSxcbiAgICAgICAgICBjb2xsZWN0aW9uUGF0aCxcbiAgICAgICAgICBjb2x1bW5QcmVmaXgsXG4gICAgICAgICAgY29uc3RyYWludFBhdGgsXG4gICAgICAgICAgY29uc3RyYWludHMsXG4gICAgICAgICAgZmllbGRzOiBmaWVsZC5maWVsZHMsXG4gICAgICAgICAgam9pbkFsaWFzZXMsXG4gICAgICAgICAgam9pbnMsXG4gICAgICAgICAgbG9jYWxlLFxuICAgICAgICAgIHBhdGhTZWdtZW50czogcGF0aFNlZ21lbnRzLnNsaWNlKDEpLFxuICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgc2VsZWN0RmllbGRzLFxuICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICB9KVxuICAgICAgfVxuXG4gICAgICBjYXNlICdncm91cCc6IHtcbiAgICAgICAgaWYgKGxvY2FsZSAmJiBmaWVsZC5sb2NhbGl6ZWQgJiYgYWRhcHRlci5wYXlsb2FkLmNvbmZpZy5sb2NhbGl6YXRpb24pIHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2xvY2FsZXNgXG5cbiAgICAgICAgICBqb2luc1t0YWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICAgIGlmIChsb2NhbGUgIT09ICdhbGwnKSB7XG4gICAgICAgICAgICBjb25zdHJhaW50cy5wdXNoKHtcbiAgICAgICAgICAgICAgY29sdW1uTmFtZTogJ19sb2NhbGUnLFxuICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgdmFsdWU6IGxvY2FsZSxcbiAgICAgICAgICAgIH0pXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGFsaWFz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G9jYWxlICE9PSAnYWxsJykge1xuICAgICAgICAgICAgY29uc3RyYWludHMucHVzaCh7XG4gICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgdGFibGU6IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0sXG4gICAgICAgICAgICAgIHZhbHVlOiBsb2NhbGUsXG4gICAgICAgICAgICB9KVxuICAgICAgICAgIH1cbiAgICAgICAgfSBlbHNlIHtcbiAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICBhZGFwdGVyLnRhYmxlc1t0YWJsZU5hbWVdLmlkLFxuICAgICAgICAgICAgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQsXG4gICAgICAgICAgKVxuICAgICAgICB9XG4gICAgICAgIHJldHVybiBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICBhZGFwdGVyLFxuICAgICAgICAgIGNvbGxlY3Rpb25QYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRQYXRoLFxuICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgIGZpZWxkczogZmllbGQuZmllbGRzLFxuICAgICAgICAgIGpvaW5BbGlhc2VzLFxuICAgICAgICAgIGpvaW5zLFxuICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICBwYXRoU2VnbWVudHM6IHBhdGhTZWdtZW50cy5zbGljZSgxKSxcbiAgICAgICAgICByb290VGFibGVOYW1lLFxuICAgICAgICAgIHNlbGVjdEZpZWxkcyxcbiAgICAgICAgICB0YWJsZU5hbWU6IG5ld1RhYmxlTmFtZSxcbiAgICAgICAgfSlcbiAgICAgIH1cblxuICAgICAgY2FzZSAnYmxvY2tzJzoge1xuICAgICAgICBsZXQgYmxvY2tUYWJsZUNvbHVtbjogVGFibGVDb2x1bW5cbiAgICAgICAgbGV0IG5ld1RhYmxlTmFtZTogc3RyaW5nXG4gICAgICAgIGNvbnN0IGhhc0Jsb2NrRmllbGQgPSBmaWVsZC5ibG9ja3Muc29tZSgoYmxvY2spID0+IHtcbiAgICAgICAgICBuZXdUYWJsZU5hbWUgPSBgJHt0YWJsZU5hbWV9X2Jsb2Nrc18ke3RvU25ha2VDYXNlKGJsb2NrLnNsdWcpfWBcbiAgICAgICAgICBsZXQgcmVzdWx0XG4gICAgICAgICAgY29uc3QgYmxvY2tDb25zdHJhaW50cyA9IFtdXG4gICAgICAgICAgY29uc3QgYmxvY2tTZWxlY3RGaWVsZHMgPSB7fVxuICAgICAgICAgIHRyeSB7XG4gICAgICAgICAgICByZXN1bHQgPSBnZXRUYWJsZUNvbHVtbkZyb21QYXRoKHtcbiAgICAgICAgICAgICAgYWRhcHRlcixcbiAgICAgICAgICAgICAgY29sbGVjdGlvblBhdGgsXG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRQYXRoOiAnJyxcbiAgICAgICAgICAgICAgY29uc3RyYWludHM6IGJsb2NrQ29uc3RyYWludHMsXG4gICAgICAgICAgICAgIGZpZWxkczogYmxvY2suZmllbGRzLFxuICAgICAgICAgICAgICBqb2luQWxpYXNlcyxcbiAgICAgICAgICAgICAgam9pbnMsXG4gICAgICAgICAgICAgIGxvY2FsZSxcbiAgICAgICAgICAgICAgcGF0aFNlZ21lbnRzOiBwYXRoU2VnbWVudHMuc2xpY2UoMSksXG4gICAgICAgICAgICAgIHJvb3RUYWJsZU5hbWUsXG4gICAgICAgICAgICAgIHNlbGVjdEZpZWxkczogYmxvY2tTZWxlY3RGaWVsZHMsXG4gICAgICAgICAgICAgIHRhYmxlTmFtZTogbmV3VGFibGVOYW1lLFxuICAgICAgICAgICAgfSlcbiAgICAgICAgICB9IGNhdGNoIChlcnJvcikge1xuICAgICAgICAgICAgLy8gdGhpcyBpcyBmaW5lLCBub3QgZXZlcnkgYmxvY2sgd2lsbCBoYXZlIHRoZSBmaWVsZFxuICAgICAgICAgIH1cbiAgICAgICAgICBpZiAoIXJlc3VsdCkge1xuICAgICAgICAgICAgcmV0dXJuXG4gICAgICAgICAgfVxuICAgICAgICAgIGJsb2NrVGFibGVDb2x1bW4gPSByZXN1bHRcbiAgICAgICAgICBjb25zdHJhaW50cyA9IGNvbnN0cmFpbnRzLmNvbmNhdChibG9ja0NvbnN0cmFpbnRzKVxuICAgICAgICAgIHNlbGVjdEZpZWxkcyA9IHsgLi4uc2VsZWN0RmllbGRzLCAuLi5ibG9ja1NlbGVjdEZpZWxkcyB9XG4gICAgICAgICAgaWYgKGZpZWxkLmxvY2FsaXplZCAmJiBhZGFwdGVyLnBheWxvYWQuY29uZmlnLmxvY2FsaXphdGlvbikge1xuICAgICAgICAgICAgam9pbnNbbmV3VGFibGVOYW1lXSA9IGFuZChcbiAgICAgICAgICAgICAgZXEoYWRhcHRlci50YWJsZXNbdGFibGVOYW1lXS5pZCwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXS5fcGFyZW50SUQpLFxuICAgICAgICAgICAgICBlcShhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLl9sb2NhbGUsIGxvY2FsZSksXG4gICAgICAgICAgICApXG4gICAgICAgICAgICBpZiAobG9jYWxlKSB7XG4gICAgICAgICAgICAgIGNvbnN0cmFpbnRzLnB1c2goe1xuICAgICAgICAgICAgICAgIGNvbHVtbk5hbWU6ICdfbG9jYWxlJyxcbiAgICAgICAgICAgICAgICB0YWJsZTogYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXSxcbiAgICAgICAgICAgICAgICB2YWx1ZTogbG9jYWxlLFxuICAgICAgICAgICAgICB9KVxuICAgICAgICAgICAgfVxuICAgICAgICAgIH0gZWxzZSB7XG4gICAgICAgICAgICBqb2luc1tuZXdUYWJsZU5hbWVdID0gZXEoXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW3RhYmxlTmFtZV0uaWQsXG4gICAgICAgICAgICAgIGFkYXB0ZXIudGFibGVzW25ld1RhYmx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xcbiAgICAgICAgICApXG4gICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgZmllbGQsXG4gICAgICAgICAgICByYXdDb2x1bW46IHNxbC5yYXcoYENPQUxFU0NFKCR7dGFibGVDb2x1bW5zTmFtZXMuam9pbignLCAnKX0pYCksXG4gICAgICAgICAgICB0YWJsZTogYWxpYXNSZWxhdGlvbnNoaXBUYWJsZSxcbiAgICAgICAgICB9XG4gICAgICAgIH0gZWxzZSBpZiAobmV3Q29sbGVjdGlvblBhdGggPT09ICdyZWxhdGlvblRvJykge1xuICAgICAgICAgIGNvbnN0IHJlbGF0aW9uVG8gPSBBcnJheS5pc0FycmF5KGZpZWxkLnJlbGF0aW9uVG8pID8gZmllbGQucmVsYXRpb25UbyA6IFtmaWVsZC5yZWxhdGlvblRvXVxuXG4gICAgICAgICAgcmV0dXJuIHtcbiAgICAgICAgICAgIGNvbnN0cmFpbnRzLFxuICAgICAgICAgICAgZmllbGQsXG4gICAgICAgICAgICBnZXROb3ROdWxsQ29sdW1uQnlWYWx1ZTogKHZhbCkgPT4ge1xuICAgICAgICAgICAgICBjb25zdCBtYXRjaGVkUmVsYXRpb24gPSByZWxhdGlvblRvLmZpbmQoKHJlbGF0aW9uKSA9PiByZWxhdGlvbiA9PT0gdmFsKVxuICAgICAgICAgICAgICBpZiAobWF0Y2hlZFJlbGF0aW9uKSByZXR1cm4gYCR7bWF0Y2hlZFJlbGF0aW9ufUlEYFxuICAgICAgICAgICAgICByZXR1cm4gdW5kZWZpbmVkXG4gICAgICAgICAgICB9LFxuICAgICAgICAgICAgdGFibGU6IGFsaWFzUmVsYXRpb25zaGlwVGFibGUsXG4gICAgICAgICAgfVxuICAgICAgICB9IGVsc2Uge1xuICAgICAgICAgIHRocm93IG5ldyBBUElFcnJvcignTm90IHN1cHBvcnRlZCcpXG4gICAgICAgIH1cblxuICAgICAgICByZXR1cm4gZ2V0VGFibGVDb2x1bW5Gc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bnNbbmV3VGFibGVOYW1lXSA9IGVxKHBhcmVudFRhYmxlLmlkLCBhZGFwdGVyLnRhYmxlc1tuZXdUYWJsZU5hbWVdLl9wYXJlbnRJRClcblxuICAgICAgICAgICAgYWxpYXNUYWJsZSA9IHVuZGVmaW5lZFxuXG4gICAgICAgICAgICBpZiAobG9jYWxlICE9PSAnYWxsJykge1xuICAgICAgICAgICAgICBjb25zdHJhaW50cy5wdXNoKHtcbiAgICAgICAgICAgICAgICBjb2x1bW5OYW1lOiAnX2xvY2FsZScsXG4gICAgICAgICAgICAgICAgdGFibGU6IGFkYXB0ZXIudGFibGVzW25ld1RhYmxlTmFtZV0sXG4gICAgICAgICAgICAgICAgdmFsdWU6IGxvY2FsZSxcbiAgICAgICAgICAgICAgfSlcbiAgICAgICAgICAgIH1cbiAgICAgICAgICB9XG5cbiAgICAgICAgICBjb25zdCB0YXJnZXRUYWJsZSA9IGFsaWFzVGFibGUgfHwgYWRhcHRlci50YWJsZXNbbmV3VGFibGVOYW1lXVxuXG4gICAgICAgICAgc2VsZWN0RmllbGRzW2Ake25ld1RhYmxlTmFtZX0uJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfWBdID1cbiAgICAgICAgICAgIHRhcmdldFRhYmxlW2Ake2NvbHVtblByZWZpeH0ke2ZpZWxkLm5hbWV9YF1cblxuICAgICAgICAgIHJldHVybiB7XG4gICAgICAgICAgICBjb2x1bW5OYW1lOiBgJHtjb2x1bW5QcmVmaXh9JHtmaWVsZC5uYW1lfWAsXG4gICAgICAgICAgICBjb25zdHJhaW50cyxcbiAgICAgICAgICAgIGZpZWxkLFxuICAgICAgICAgICAgcGF0aFNlZ21lbnRzOiBwYXRoU2VnbWVudHMsXG4gICAgICAgICAgICB0YWJsZTogdGFyZ2V0VGFibGUsXG4gICAgICAgICAgfVxuICAgICAgICB9XG4gICAgICB9XG4gICAgfVxuICB9XG5cbiAgdGhyb3cgbmV3IEFQSUVycm9yKGBDYW5ub3QgZmluZCBm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QixNQUFNLENBQUNGLGFBQWE7b0NBQ25DcUIsT0FBT3BDO2dDQUNUOzRCQUNGO3dCQUNGO3dCQUVBLE1BQU04RSxjQUFjdkYsY0FBY0QsUUFBUTJCLE1BQU0sQ0FBQ0YsYUFBYTt3QkFFOURULFlBQVksQ0FBQyxDQUFDLEVBQUVTLGFBQWEsQ0FBQyxFQUFFdEIsYUFBYSxFQUFFZ0IsTUFBTUssSUFBSSxDQUFDLENBQUMsQ0FBQyxHQUMxRGdFLFdBQVcsQ0FBQyxDQUFDLEVBQUVyRixhQUFhLEVBQUVnQixNQUFNSyxJQUFJLENBQUMsQ0FBQyxDQUFDO3dCQUU3QyxPQUFPOzRCQUNMSSxZQUFZLENBQUMsRUFBRXpCLGFBQWEsRUFBRWdCLE1BQU1LLElBQUksQ0FBQyxDQUFDOzRCQUMxQ2xCOzRCQUNBYTs0QkFDQVAsY0FBY0E7NEJBQ2RrQixPQUFPMEQ7d0JBQ1Q7b0JBQ0Y7Z0JBQ0Y7UUFDRjtJQUNGO0lBRUEsTUFBTSxJQUFJMUIsZ0JBQVEsQ0FBQyxDQUFDLDhCQUE4QixFQUFFNUMsVUFBVSxDQUFDO0FBQ2pFIn0=
@@ -21,7 +21,7 @@ const insertArrays = async ({ adapter, arrays, db, parentRows })=>{
21
21
  rows: []
22
22
  };
23
23
  }
24
- const parentID = parentRows[parentRowIndex].id;
24
+ const parentID = parentRows[parentRowIndex].id || parentRows[parentRowIndex]._parentID;
25
25
  // Add any sub arrays that need to be created
26
26
  // We will call this recursively below
27
27
  arrayRows.forEach((arrayRow)=>{
@@ -61,4 +61,4 @@ const insertArrays = async ({ adapter, arrays, db, parentRows })=>{
61
61
  }
62
62
  };
63
63
 
64
- //# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIi4uLy4uL3NyYy91cHNlcnRSb3cvaW5zZXJ0QXJyYXlzLnRzIl0sInNvdXJjZXNDb250ZW50IjpbIi8qIGVzbGludC1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ElBQUlULE9BQU8sQ0FBQ08sTUFBTSxHQUFHLEdBQUc7WUFDcEUsTUFBTWpCLEdBQUd1QixNQUFNLENBQUN6QixRQUFRMEIsTUFBTSxDQUFDLENBQUMsRUFBRWhCLFVBQVUsUUFBUSxDQUFDLENBQUMsRUFBRWlCLE1BQU0sQ0FBQ04sSUFBSVQsT0FBTyxFQUFFZ0IsU0FBUztRQUN2RjtRQUVBLDBEQUEwRDtRQUMxRCxJQUFJUCxJQUFJcEIsTUFBTSxDQUFDa0IsTUFBTSxHQUFHLEdBQUc7WUFDekIsTUFBTXBCLGFBQWE7Z0JBQ2pCQztnQkFDQUMsUUFBUW9CLElBQUlwQixNQUFNO2dCQUNsQkM7Z0JBQ0FDLFlBQVlrQixJQUFJUixJQUFJO1lBQ3RCO1FBQ0Y7SUFDRjtBQUNGIn0=
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@payloadcms/db-postgres",
3
- "version": "0.1.13",
3
+ "version": "0.2.1",
4
4
  "description": "The officially supported Postgres database adapter for Payload",
5
5
  "repository": "https://github.com/payloadcms/payload",
6
6
  "license": "MIT",
@@ -19,13 +19,14 @@
19
19
  "drizzle-orm": "0.28.5",
20
20
  "pg": "8.11.3",
21
21
  "prompts": "2.4.2",
22
- "to-snake-case": "1.0.0"
22
+ "to-snake-case": "1.0.0",
23
+ "uuid": "9.0.0"
23
24
  },
24
25
  "devDependencies": {
25
26
  "@types/pg": "8.10.2",
26
27
  "@types/to-snake-case": "1.0.0",
27
28
  "@payloadcms/eslint-config": "1.0.0",
28
- "payload": "2.1.0"
29
+ "payload": "2.4.0"
29
30
  },
30
31
  "peerDependencies": {
31
32
  "payload": "^2.0.0"