scheduler-node-models 1.2.73 → 1.2.74

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "scheduler-node-models",
3
- "version": "1.2.73",
3
+ "version": "1.2.74",
4
4
  "main": "index.js",
5
5
  "types": "index.d.ts",
6
6
  "files": [
@@ -50,21 +50,23 @@ class ExcelRowIngest {
50
50
  const worksheet = workbook.getWorksheet('Sheet1');
51
51
  if (worksheet) {
52
52
  worksheet.eachRow(async (row, r) => {
53
- const name = row.getCell(1).toString().trim();
54
- if (name.includes(',')) {
55
- console.log(name);
56
- if (this.site.employees) {
57
- const emp = this.site.employees.find(e => e.name.getLastFirst().toLowerCase() === name.toLowerCase());
58
- if (emp) {
59
- for (let c = 3; c < 34; c++) {
60
- const results = await this.readExcelRow(row, c, emp);
61
- console.log(results.length);
62
- result.push(...results);
53
+ if (row.getCell(1)) {
54
+ const name = row.getCell(1).toString().trim();
55
+ if (name.includes(',')) {
56
+ console.log(name);
57
+ if (this.site.employees) {
58
+ const emp = this.site.employees.find(e => e.name.getLastFirst().toLowerCase() === name.toLowerCase());
59
+ if (emp) {
60
+ for (let c = 3; c < 34; c++) {
61
+ const results = await this.readExcelRow(row, c, emp);
62
+ console.log(results.length);
63
+ result.push(...results);
64
+ }
63
65
  }
64
66
  }
65
- }
66
- else {
67
- throw new Error('No employees in site');
67
+ else {
68
+ throw new Error('No employees in site');
69
+ }
68
70
  }
69
71
  }
70
72
  });