@optimiser/common 1.0.351 → 1.0.353

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.
@@ -364,7 +364,7 @@ var UpdateInitialSyncData = function (params) { return __awaiter(void 0, void 0,
364
364
  _a.trys.push([0, 3, , 4]);
365
365
  if (!params) return [3 /*break*/, 2];
366
366
  updatedData = null;
367
- return [4 /*yield*/, params.db.collection(params.Collection).update({ '_id': params.Id }, { $set: params.UpdateObj }, mongodbQueryOpts)];
367
+ return [4 /*yield*/, params.db.collection(params.Collection).updateOne({ '_id': params.Id }, { $set: params.UpdateObj }, mongodbQueryOpts)];
368
368
  case 1:
369
369
  updatedData = _a.sent();
370
370
  if (updatedData) {
@@ -5546,7 +5546,7 @@ function SyncTotalSlotRemaining(registrationID, db) {
5546
5546
  case 5:
5547
5547
  registeredDelegates = _a.sent();
5548
5548
  // let registeredDelegates = delegatesAllData.filter(x => x.RegistrationType == registrationID.toString() && x._id !== delegateID);
5549
- if (registeredDelegates) {
5549
+ if (registeredDelegates && registeredDelegates.length) {
5550
5550
  if (includeGuestInRegCount) {
5551
5551
  totalDelegates = registeredDelegates.filter(function (x) { return regDelegates_1.includes(x.status); }).length;
5552
5552
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optimiser/common",
3
- "version": "1.0.351",
3
+ "version": "1.0.353",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {