@optimiser/common 1.0.376 → 1.0.377

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.
@@ -4810,8 +4810,12 @@ function ValidateUserInput(options) {
4810
4810
  return [4 /*yield*/, db.collection(objectName).findOne({ '_id': documentID })];
4811
4811
  case 2:
4812
4812
  parentData = _k.sent();
4813
- oldValue = parentData[fieldName];
4813
+ oldValue = parentData[fieldName] || null;
4814
4814
  newValue = fieldData;
4815
+ // Check if newValue is undefined
4816
+ if (newValue === undefined) {
4817
+ return [2 /*return*/, "break"];
4818
+ }
4815
4819
  isSame = false;
4816
4820
  if (field.UIDataType == 'multiselect' || field.UIDataType == 'multilookup') {
4817
4821
  isSame = IsEqualArrays(oldValue, newValue);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@optimiser/common",
3
- "version": "1.0.376",
3
+ "version": "1.0.377",
4
4
  "description": "",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {